replication-walkthrough-5
Example 5: S3 Replication Time Control (S3 RTC) configuration
S3 Replication Time Control (S3 RTC) helps you meet compliance or business requirements for data replication and provides visibility into Amazon S3 replication times. S3 RTC replicates most objects that you upload to Amazon S3 in seconds, and 99.99 percent of those objects within 15 minutes.
With S3 RTC, you can monitor the total number and size of objects that are pending replication, and the maximum replication time to the destination Region. Replication metrics are available through the AWS Management Console and Amazon CloudWatch User Guide;. For more information, see Amazon S3 CloudWatch Replication Metrics
Topics
Enable S3 RTC on the Amazon S3 Console
For step-by-step instructions, see How Do I Add a Replication Rule to an S3 Bucket? in the Amazon Simple Storage Service Console User Guide. This topic provides instructions for enabling S3 RTC in your replication configuration when buckets are owned by same and different AWS accounts.
Replicate Objects with Amazon S3 Replication Time Control(AWS CLI)
To replicate objects with S3 RTC enabled onwith the AWS CLI, you create buckets, enable versioning on the buckets, create an IAM role that gives Amazon S3 permission to replicate objects, and add the replication configuration to the source bucket. The replication configuration needs to have S3 Replication Time Control (S3 RTC) enabled.
To replicate with S3 RTC enabled (AWS CLI)
In this example, we set
ReplicationTime
andMetric
and add replication configuration to the source bucket.{"Rules": [{"Status": "Enabled","Filter": {"Prefix": "Tax"},"DeleteMarkerReplication": {"Status": "Disabled"},"Destination": {"Bucket": "arn:aws:s3:::destination","Metrics": {"Status": "Enabled","EventThreshold": {"Minutes": 15}},"ReplicationTime": {"Status": "Enabled","Time": {"Minutes": 15}}},"Priority": 1}],"Role": "IAM-Role-ARN"}Important
Metrics:EventThreshold:Minutes
andReplicationTime:Time:Minutes
can only have 15 is a valid value.
Replicate Objects with Amazon S3 Replication Time Control (AWS SDK)
Below is a java example to add replication configuration with S3 Replication Time Control (S3 RTC):
For more information, see Replicating Objects Using S3 Replication Time Control (S3 RTC).