uploads as atomic transactions
|Reported by:||mindplay||Owned by:|
|Keywords:||Cc:||mindplay, cybot_tm, Alexander Schuch, Tim Kosse|
|Component version:||Operating system type:|
|Operating system version:|
uploads are currently progressive - that is, the file is created in it's destination, and is then gradually appended during upload.
in order to cooperate well with other server software (e.g. scheduled tasks, pickup scripts, etc.) uploads need to be atomic transactions - that is, the physical file needs to be created "invisibly", in a temporary folder on the destination drive.
once the upload is completed, the file can then be renamed to it's destination filename/folder.
this way, pickup scripts, scheduled tasks, backup applications, etc. will never find a partially uploaded file.
this is crucial if, for example, you have a script that picks up a CSV file on a schedule - currently, if you're unlucky, you'll pick up the file while it's incomplete, and your data will only be partially imported.