Difference between Amazon S3 Cross-Zone Replication and Cloud

After reading some AWS docs, I wonder what the difference is between these different use cases if I want to receive (js, css, images and api request) in Asia (including China), USA and EU.

  • Save my images and static files in the S3 region in the USA and set up cross-region replication in the EU and Asia (Japan or Singapore) to synchronize with the US region S3.

  • Save my images and static files in the US region S3 and set up a cloud-based CDN to cache my content in different places after the initial request.

  • Do both above (if there is a significant performance improvement).

What is the most economical solution if I need to achieve global deployment? And how to make the request from China consistent and stable (I tried cloudfront + s3 (us-west), it is fast, but the performance does not match)?

PS. At an early stage, I do not expect too many user requests, but users are distributed around the world, and I want them to have a similar experience. Most of my content is panoramic images, which I would expect to download every 30 megabytes (10 high-resolution images) in each visit.

+5
source share
1 answer

Regional replication copies everything in a bucket in one area to another bucket in another region. This is only valid for additional backup / redundancy if the entire AWS area decreases. This has nothing to do with performance. Note that it replicates to a different bucket , so you will need to use different URLs to access the files in each bucket.

CloudFront is a content delivery network. S3 is just a file storage service. Working with a file directly from S3 can have performance problems, so it is recommended to put a CDN in front of S3. It looks like you definitely need a CDN, and it looks like you tested CloudFront and were not impressed. It also sounds like you need a CDN with a big presence in China.

There is no reason you should choose CloudFront as your CDN just because you use other AWS services. You should look at other CDN services and see what their border network looks like. Based on your requirements, I highly recommend you take a look at CloudFlare . They have quite a few border networks in China.

Another option would be to use a CDN, on which you can actually click your files. I have used this feature in the past with MaxCDN . You upload your files to the CDN via FTP, and the files will be automatically transferred to all peripheral network locations and cached until you click update. For your case of using large image downloads, this may provide a more efficient caching mechanism. MaxCDN does not seem to have a large presence in China, and bandwidth charges will be more expensive than CloudFlare.

+6
source

Source: https://habr.com/ru/post/1236480/


All Articles