What is better for serving stati开发者_如何学编程c files of most websites (javascripts, css, images, html): S3, something like EC2 or yet another option?
S3 with CloudFront enabled would be my choice; then you get the benefits from S3, plus fast access for your users through their edge-locations.
If you have some really high performance demands, you should look into something that is physically located near your users. In my case, swedish providers are a bit faster than any of Amazons solutions (but usually not as nice to use).
EC2 is not really made for static files (or rather, it's made for so much more).
Why go to the trouble of EC2 when Amazon S3 will do this for you, and is a LOT easier manage? Just use something like BucketExplorer for upload/download, and you don't need to worry about starting images, making sure they're still running, keeping software versions unto date, paying for idle time, etc.
Also look at Amazon's CloudFront service, which is a CDN for Amazon S3. It may or not be economic for you, but it can greatly improve download times for your users.
精彩评论