S3 Features: Cross-Origin Resource Sharing (CORS) and Cross Region Replication (CRR) Overview

S3 Cross-Origin Resource Sharing (CORS)

Cross-origin resource sharing (CORS) defines a way for client web applications that are loaded in one domain to interact with resources in a different domain. 

Example scenarios:

  1. Allow JavaScript on the web pages that are stored in a bucket to be able to make authenticated GET and PUT requests against the same bucket by using the Amazon S3's API endpoint for the bucket.

  2. You host a web font from your S3 bucket. Browsers require a CORS check (also referred as a preflight check) for loading web fonts.

 

Cross Region Replication (CRR)

  1. CRR allows to automatically replicate data across AWS regions.

  2. Every object uploaded to an S3 bucket is replicated to a destination bucket, along with metadata and ACLs associated with the object.

  3. Any change to the underlying data, metadata, or ACLs on the object would trigger a new replication.

  4. You can either choose to replicate all objects or just a subset of objects by specifying prefixes.

  5. Existing data in the bucket prior to enabling CRR is not replicated.

  6. You may use S3’s COPY API to copy the existing data.  

  7. You can configure separate lifecycle rules on the source and destination buckets.

  8. Deleting a file in bucket will delete in the replication bucket. However Undo Delete is not replicated.

  9. Cannot replicate to more than one destination in cross-region replication.

  10. Can’t use cross-region replication to replicate within same region.

  11. You enable CRR configuration on source bucket by specifying a destination bucket in a different region.

  12. You can use either the Management Console, the REST API, the AWS CLI, or the AWS SDKs to enable CRR.

  13. Versioning must be turned on for both the source and destination buckets to enable CRR.

  14. Can use CRR to provide lower-latency data access in different geographic regions. CRR can help if you have a compliance requirement to store copies of data hundreds of miles apart.

  15. Pricing: You pay the Amazon S3 charges for storage, requests, and inter-region data transfer for the replicated copy of data.

Learn Serverless from Serverless Programming Cookbook

Contact

Please first use the contact form or facebook page messaging to connect.

Offline Contact
We currently connect locally for discussions and sessions at Bangalore, India. Please follow us on our facebook page for details.
WhatsApp (Primary): (+91) 7411174113
Phone (Escalations): (+91) 7411174114

Business newsletter

Complete the form below, and we'll send you an e-mail every now and again with all the latest news.

About

CloudMaterials is my blog to share notes and learning materials on Cloud and Data Analytics. My current focus is on Microsoft Azure and Amazon Web Services (AWS).

I like to write and I try to document what I learn to share with others. I believe that knowledge is useless unless you share it; the more you share, the more you learn.

Recent comments

Photo Stream