5

AWS S3 - Prevent object overwrite

view full story
linux-howto

http://serverfault.com – I'm trying to speed up a transfer of images from our web server to S3. Some of the images have been uploaded already, but the process was interrupted. We've written new scripts to upload images if they don't already exist in S3, however the if_object_exists() method seems to be quite slow (1-2 seconds). We're thinking of just attempting to upload every image, but make S3 fail if the object exists (hoping this will be faster). Does anyone know if there's a "bucket policy" or some other setting we can use to prevent overwrites? (HowTos)