I am writing a web app, and not sure about how to upload multiple images. I want to make sure that either all images are uploaded successfully, or none of them.
One way is to upload them simultaneously in several thread. However, if one of the uploading process fails, it is difficult to cancel other process and remove uploaded images.
The solution I come up with is to combine the multiple files into a bigger file using some separator, and then server then separates it into original files.
Is my solution appropriate? Or are there any better solutions?