We are looking at an option for uploading large files (in ~100MB+) to S3.
The html-form also contains other meta information about the file, that will be stored in our application database and not in S3. Based on the success/failure of the file-upload to S3, the metadata about the image will be inserted to our application DB.
The application is on Ruby-on-Rails stack and is HTTPS enabled. Form submission to S3, is ruled out, so is a flash based upload. All the other choices we have cons开发者_运维知识库idered, have their own limitations.
Direct JS upload is not possible because of cross-domain (CORS) limitation with S3.
Configuring the HTTP server (nginx) with OPTIONS as mentioned here (http://zefer.posterous.com/pure-html-ajax-solutions-to-upload-files-to-s). But the application (i.e, nginx) will run behind ElasticLoadBalancer on HTTPS. Is there a better way to handle this requirement on ELB ?
Are there other good patterns for this requirement in AWS World ?
Thanks, Sriram
CORS is now supported, so your option 1 will now work http://aws.typepad.com/aws/2012/08/amazon-s3-cross-origin-resource-sharing.html
Why do you say form submission is ruled out?
http://docs.amazonwebservices.com/AmazonS3/latest/dev/HTTPPOSTForms.html
精彩评论