There are two reasons for uploading a file in chunks:
File upload may get interrupted so it is nice to continue when it ended
File upload size is often limited to few megabytes so this would avoid this limitation and would work for any file size (videos).
Idea is to send file in chunks of some reasonable size, one chunk per http request. Once all chunks are transfered, the completed file is renamed to original name.
Basically the one thing to add is offset and length of the chunk and seek before writing. A hash of the whole file would be nice to check to be sure no chunk is missing.
There are two reasons for uploading a file in chunks:
Idea is to send file in chunks of some reasonable size, one chunk per http request. Once all chunks are transfered, the completed file is renamed to original name.
Basically the one thing to add is offset and length of the chunk and seek before writing. A hash of the whole file would be nice to check to be sure no chunk is missing.