开发者

Should I use Amazon S3 for my images or just keep them local on my server?

I have about 15 high res background images for my site, each weigh a开发者_如何学编程round 500 MB. Im wondering if there is an advantage to storing them on Amazon S3 instead of my own web server. It seems like the pages should load faster if local to my server, but not sure


My experience with S3 is that it may not be fast because there is a latency that is significant. But the main advantage is that is supposed to be constant and reliable, something that probably you cannot say about a private hosting.

If you decide to use S3, one important detail is choosing the zone (US-East, US-West, Europe, Asia) according to the location of your users. That may reduce the latency.

And another detail is the pricing ( http://aws.amazon.com/s3/#pricing ). With those prices you'll pay about $ 0,1 for each 2K requests of your 500 Kb backgrounds, which in my opinion is cheap.


500mb each is going to be very slow either way. However, if you must have such huge images, S3 with Cloud Front serving it up is likely faster (not sure about that large of files though). I would do both repeatedly (S3 and local) to measure the difference.


500KB you mean?

What you are describing is called a content delivery network or CDN, offloading images from your own webserver to a CDN can be very worthwhile in the right situations. I run a site where where 50% of our hits and 66% of our bandwidth came from images, and we were saturating our pipe.

Rather than spending the $$ to upgrade our link at the colocation facility, we put all our images on a CDN. Instant reduction in both bandwidth AND CPU load from the web server having to serve up static images. That basically gave us another year of growth before we had to do something else.

Amazon S3 isn't really a CDN, we looked into using it as such and a lot of the feedback I found indicated that the big problem was going to be latency, and since in our use case we had many small images to serve up, latency was a factor. So we went with another CDN, but Amazon CloudFront would have been appropriate for that. In our case the cost per request would have been too much for us.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜