Class: AWSCDK::S3::CfnBucket::ReplicationDestinationProperty
- Inherits:
-
Jsii::Struct
- Object
- Jsii::Struct
- AWSCDK::S3::CfnBucket::ReplicationDestinationProperty
- Defined in:
- s3/cfn_bucket.rb
Overview
A container for information about the replication destination and its configurations including enabling the S3 Replication Time Control (S3 RTC).
Instance Attribute Summary collapse
-
#access_control_translation ⇒ AWSCDK::IResolvable, ...
readonly
Specify this only in a cross-account scenario (where source and destination bucket owners are not the same), and you want to change replica ownership to the AWS account that owns the destination bucket.
-
#account ⇒ String?
readonly
Destination bucket owner account ID.
-
#bucket ⇒ String
readonly
The Amazon Resource Name (ARN) of the bucket where you want Amazon S3 to store the results.
-
#encryption_configuration ⇒ AWSCDK::IResolvable, ...
readonly
Specifies encryption-related information.
-
#metrics ⇒ AWSCDK::IResolvable, ...
readonly
A container specifying replication metrics-related settings enabling replication metrics and events.
-
#replication_time ⇒ AWSCDK::IResolvable, ...
readonly
A container specifying S3 Replication Time Control (S3 RTC), including whether S3 RTC is enabled and the time when all objects and operations on objects must be replicated.
-
#storage_class ⇒ String?
readonly
The storage class to use when replicating objects, such as S3 Standard or reduced redundancy.
Class Method Summary collapse
Instance Method Summary collapse
-
#initialize(bucket:, access_control_translation: nil, account: nil, encryption_configuration: nil, metrics: nil, replication_time: nil, storage_class: nil) ⇒ ReplicationDestinationProperty
constructor
A new instance of ReplicationDestinationProperty.
- #to_jsii ⇒ Object
Constructor Details
#initialize(bucket:, access_control_translation: nil, account: nil, encryption_configuration: nil, metrics: nil, replication_time: nil, storage_class: nil) ⇒ ReplicationDestinationProperty
Returns a new instance of ReplicationDestinationProperty.
3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 |
# File 's3/cfn_bucket.rb', line 3391 def initialize(bucket:, access_control_translation: nil, account: nil, encryption_configuration: nil, metrics: nil, replication_time: nil, storage_class: nil) @bucket = bucket Jsii::Type.check_type(@bucket, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "bucket") @access_control_translation = access_control_translation.is_a?(Hash) ? ::AWSCDK::S3::CfnBucket::AccessControlTranslationProperty.new(**access_control_translation.transform_keys(&:to_sym)) : access_control_translation Jsii::Type.check_type(@access_control_translation, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19zMy5DZm5CdWNrZXQuQWNjZXNzQ29udHJvbFRyYW5zbGF0aW9uUHJvcGVydHkifV19fQ==")), "accessControlTranslation") unless @access_control_translation.nil? @account = account Jsii::Type.check_type(@account, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "account") unless @account.nil? @encryption_configuration = encryption_configuration.is_a?(Hash) ? ::AWSCDK::S3::CfnBucket::EncryptionConfigurationProperty.new(**encryption_configuration.transform_keys(&:to_sym)) : encryption_configuration Jsii::Type.check_type(@encryption_configuration, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19zMy5DZm5CdWNrZXQuRW5jcnlwdGlvbkNvbmZpZ3VyYXRpb25Qcm9wZXJ0eSJ9XX19")), "encryptionConfiguration") unless @encryption_configuration.nil? @metrics = metrics.is_a?(Hash) ? ::AWSCDK::S3::CfnBucket::MetricsProperty.new(**metrics.transform_keys(&:to_sym)) : metrics Jsii::Type.check_type(@metrics, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19zMy5DZm5CdWNrZXQuTWV0cmljc1Byb3BlcnR5In1dfX0=")), "metrics") unless @metrics.nil? @replication_time = replication_time.is_a?(Hash) ? ::AWSCDK::S3::CfnBucket::ReplicationTimeProperty.new(**replication_time.transform_keys(&:to_sym)) : replication_time Jsii::Type.check_type(@replication_time, JSON.parse(Base64.strict_decode64("eyJ1bmlvbiI6eyJ0eXBlcyI6W3siZnFuIjoiYXdzLWNkay1saWIuSVJlc29sdmFibGUifSx7ImZxbiI6ImF3cy1jZGstbGliLmF3c19zMy5DZm5CdWNrZXQuUmVwbGljYXRpb25UaW1lUHJvcGVydHkifV19fQ==")), "replicationTime") unless @replication_time.nil? @storage_class = storage_class Jsii::Type.check_type(@storage_class, JSON.parse(Base64.strict_decode64("eyJwcmltaXRpdmUiOiJzdHJpbmcifQ==")), "storageClass") unless @storage_class.nil? end |
Instance Attribute Details
#access_control_translation ⇒ AWSCDK::IResolvable, ... (readonly)
Specify this only in a cross-account scenario (where source and destination bucket owners are not the same), and you want to change replica ownership to the AWS account that owns the destination bucket.
If this is not specified in the replication configuration, the replicas are owned by same AWS account that owns the source object.
3419 3420 3421 |
# File 's3/cfn_bucket.rb', line 3419 def access_control_translation @access_control_translation end |
#account ⇒ String? (readonly)
Destination bucket owner account ID.
In a cross-account scenario, if you direct Amazon S3 to change replica ownership to the AWS account that owns the destination bucket by specifying the AccessControlTranslation property, this is the account ID of the destination bucket owner. For more information, see Cross-Region Replication Additional Configuration: Change Replica Owner in the Amazon S3 User Guide .
If you specify the AccessControlTranslation property, the Account property is required.
3428 3429 3430 |
# File 's3/cfn_bucket.rb', line 3428 def account @account end |
#bucket ⇒ String (readonly)
The Amazon Resource Name (ARN) of the bucket where you want Amazon S3 to store the results.
3412 3413 3414 |
# File 's3/cfn_bucket.rb', line 3412 def bucket @bucket end |
#encryption_configuration ⇒ AWSCDK::IResolvable, ... (readonly)
Specifies encryption-related information.
3433 3434 3435 |
# File 's3/cfn_bucket.rb', line 3433 def encryption_configuration @encryption_configuration end |
#metrics ⇒ AWSCDK::IResolvable, ... (readonly)
A container specifying replication metrics-related settings enabling replication metrics and events.
3438 3439 3440 |
# File 's3/cfn_bucket.rb', line 3438 def metrics @metrics end |
#replication_time ⇒ AWSCDK::IResolvable, ... (readonly)
A container specifying S3 Replication Time Control (S3 RTC), including whether S3 RTC is enabled and the time when all objects and operations on objects must be replicated.
Must be specified together with a Metrics block.
3445 3446 3447 |
# File 's3/cfn_bucket.rb', line 3445 def replication_time @replication_time end |
#storage_class ⇒ String? (readonly)
The storage class to use when replicating objects, such as S3 Standard or reduced redundancy.
By default, Amazon S3 uses the storage class of the source object to create the object replica.
For valid values, see the StorageClass element of the PUT Bucket replication action in the Amazon S3 API Reference .
FSX_OPENZFS is not an accepted value when replicating objects.
3456 3457 3458 |
# File 's3/cfn_bucket.rb', line 3456 def storage_class @storage_class end |
Class Method Details
.jsii_properties ⇒ Object
3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 |
# File 's3/cfn_bucket.rb', line 3458 def self.jsii_properties { :bucket => "bucket", :access_control_translation => "accessControlTranslation", :account => "account", :encryption_configuration => "encryptionConfiguration", :metrics => "metrics", :replication_time => "replicationTime", :storage_class => "storageClass", } end |
Instance Method Details
#to_jsii ⇒ Object
3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 |
# File 's3/cfn_bucket.rb', line 3470 def to_jsii result = {} result.merge!({ "bucket" => @bucket, "accessControlTranslation" => @access_control_translation, "account" => @account, "encryptionConfiguration" => @encryption_configuration, "metrics" => @metrics, "replicationTime" => @replication_time, "storageClass" => @storage_class, }) result.compact end |