any garbage files left if user close browser?

classic Classic list List threaded Threaded
6 messages Options
Reply | Threaded
Open this post in threaded view
|

any garbage files left if user close browser?

George2
Hello everyone, 1. Are there any garbage files (or memory leak, unused memory block for unfinished files) left at server side if end user close browse or close progress bar or cancel upload in the middle? I am using IIS 7.0. 2. If no to (1), I want to learn which part of code handles this issue? thanks in advance, George
Reply | Threaded
Open this post in threaded view
|

Re: any garbage files left if user close browser?

Dean Brettle
Administrator
Closing the progress bar would not interrupt the upload.  The upload would be interrupted if the user clicks the cancel button in the progress bar, clicks the browser's stop button, closes the window where the upload is occuring, or navigates to another page in the window where the upload is occuring.  Typically, the temp files are deleted as soon as the upload is interrupted.  If you are experiencing different behavior or know of a memory leak, please report it.

--Dean
Reply | Threaded
Open this post in threaded view
|

Re: any garbage files left if user close browser?

Guest-974
Cool, Dean! I did not experience this issue yet, just curious. :-) About "the temp files are deleted as soon as the upload is interrupted" -- I am interested how to implement this feature in NeatUpload (just brief idea is fine), if you could let me know in which function/class do you implement this feature, it will be even better! I want to know more about NeatUpload in order to customize more in the future, e.g. to log who cancelled upload or even implement resume upload in the future! regards, George
Reply | Threaded
Open this post in threaded view
|

Re: any garbage files left if user close browser?

Dean Brettle
Administrator
The logic is a bit spread out. Search for "FilesToDispose" to get started. --Dean
Reply | Threaded
Open this post in threaded view
|

Re: any garbage files left if user close browser?

Guest-974
Thanks Dean, 1. I read the related part of code, looks like you rely on .Net's nature that object will always be disposed by GC, correct? 2. If .Net runtime crashes, there will be garbage file left in theory, correct?
Reply | Threaded
Open this post in threaded view
|

Re: any garbage files left if user close browser?

Dean Brettle
Administrator
1. No. My choice of the word Dispose() was unfortunate. There is an EndRequest handler that calls Dispose() on each of the files. 2. Yes. If asp.net crashes temp any existing temp files will not be deleted. --Dean