Interface TableV2MultiAccountReplicaProps

All Superinterfaces:
software.amazon.jsii.JsiiSerializable, TableOptionsV2
All Known Implementing Classes:
TableV2MultiAccountReplicaProps.Jsii$Proxy

@Generated(value="jsii-pacmak/1.126.0 (build 206d44b)", date="2026-02-23T18:58:17.289Z") @Stability(Stable) public interface TableV2MultiAccountReplicaProps extends software.amazon.jsii.JsiiSerializable, TableOptionsV2
Properties for creating a multi-account replica table.

Note: partitionKey, sortKey, and localSecondaryIndexes are not options because CloudFormation automatically inherits the key schema and LSIs from the source table via globalTableSourceArn.

Example:

 import software.amazon.awscdk.*;
 App app = new App();
 // Source table in Account A
 Stack sourceStack = Stack.Builder.create(app, "SourceStack")
         .env(Environment.builder().region("us-east-2").account("111111111111").build())
         .build();
 TableV2 sourceTable = TableV2.Builder.create(sourceStack, "SourceTable")
         .tableName("MyMultiAccountTable")
         .partitionKey(Attribute.builder().name("pk").type(AttributeType.STRING).build())
         .globalTableSettingsReplicationMode(GlobalTableSettingsReplicationMode.ALL)
         .build();
 // Replica stack in Account B
 Stack replicaStack = Stack.Builder.create(app, "ReplicaStack")
         .env(Environment.builder().region("us-east-1").account("222222222222").build())
         .build();
 // Create replica - permissions are automatically configured
 TableV2MultiAccountReplica replica = TableV2MultiAccountReplica.Builder.create(replicaStack, "ReplicaTable")
         .tableName("MyMultiAccountTable")
         .replicaSourceTable(sourceTable)
         .globalTableSettingsReplicationMode(GlobalTableSettingsReplicationMode.ALL)
         .build();
 
  • Method Details

    • getEncryption

      @Stability(Stable) @Nullable default TableEncryptionV2 getEncryption()
      The server-side encryption configuration for the replica table.

      Note: Each replica manages its own encryption independently. This is not synchronized across replicas.

      Default: TableEncryptionV2.dynamoOwnedKey()

    • getGlobalTableSettingsReplicationMode

      @Stability(Stable) @Nullable default GlobalTableSettingsReplicationMode getGlobalTableSettingsReplicationMode()
      Controls whether table settings are synchronized across replicas.

      When set to ALL, synchronizable settings (billing mode, throughput, TTL, streams view type, GSIs) are automatically replicated across all replicas. When set to NONE, each replica manages its own settings independently (billing mode must be PAY_PER_REQUEST).

      Note: Some settings are always synchronized (key schema, LSIs) regardless of this setting, and some are never synchronized (table class, SSE, deletion protection, PITR, tags, resource policy).

      Default: GlobalTableSettingsReplicationMode.ALL

    • getGrantIndexPermissions

      @Stability(Stable) @Nullable default Boolean getGrantIndexPermissions()
      Whether or not to grant permissions for all indexes of the table.

      Note: If false, permissions will only be granted to indexes when globalIndexes is specified.

      Default: false

    • getRemovalPolicy

      @Stability(Stable) @Nullable default RemovalPolicy getRemovalPolicy()
      The removal policy applied to the table.

      Default: RemovalPolicy.RETAIN

    • getReplicaSourceTable

      @Stability(Stable) @Nullable default ITableV2 getReplicaSourceTable()
      The source table to replicate from.

      [disable-awslint:prefer-ref-interface]

      Default: - must be provided

    • getTableName

      @Stability(Stable) @Nullable default String getTableName()
      Enforces a particular physical table name.

      Default: - generated by CloudFormation

    • builder

      @Stability(Stable) static TableV2MultiAccountReplicaProps.Builder builder()
      Returns:
      a TableV2MultiAccountReplicaProps.Builder of TableV2MultiAccountReplicaProps