B4J Question Unlock file

wl

Well-Known Member
Licensed User
Longtime User
Hi,

I have a B4J HTTP server from which a client can download a file and after the file is download the client instructs the server to delete the file.

When the download of the file is interrupted: the client tries to download the file a second time and afterwards tries to deleted the file. However, this is not working as the file is still being locked by the first server thread ?

Any ideas ?

Thanks
 

Harris

Expert
Licensed User
Longtime User
The download job was not (likely) released.
Do you have a code example?
 
Upvote 0

wl

Well-Known Member
Licensed User
Longtime User
I added a try catch in the HTTP handler and made sure the stream is closed after the everything went well, or went something was wrong (so after the catch): now it is OK.

Thanks
 
Upvote 0
Top