Community
Participate
Working Groups
While testing the upload widget, I found out that the underlying apache library creates temporary files for bigger uploads. These files are created in the local temp directory of the server. In some cases these files are never deleted to the point that my harddrive was full (testing with big files). This is reproduceable with the upload demo. In some cases the files are deleted. But most of the time they are never deleted even after the shutdown of the server. From my understanding these temp files should be deleted automatically by the gargabe collector after there is no more reference to it. I made a patch which deletes the temporary files after a reset/dispose of the upload-widget.
Created attachment 183116 [details] Patch with auto-delete on reset/dispose
The upload widget is obsolete and will be removed in the future. Use the new FileUpload widget or the FileDialog implementation from the incubator instead. Actually, this issue also exists with the new DiskFileUploadReceiver. Anyway, how should the framework decide when to cleanup files? Instead of adding cleanup functionality to this default implementation, we'd rather leave the decision to the user. With the new design, you can provide your own FileUploadReceiver that cleans up files after a certain interval.