| Modifier and Type | Method and Description |
|---|---|
Table.Builder |
billingMode(BillingMode billingMode)
Specify how you are charged for read and write throughput and how you manage capacity.
|
Table |
build() |
Table.Builder |
contributorInsightsEnabled(Boolean contributorInsightsEnabled)
Whether CloudWatch contributor insights is enabled.
|
static Table.Builder |
create(software.constructs.Construct scope,
String id) |
Table.Builder |
encryption(TableEncryption encryption)
Whether server-side encryption with an AWS managed customer master key is enabled.
|
Table.Builder |
encryptionKey(IKey encryptionKey)
External KMS key to use for table encryption.
|
Table.Builder |
kinesisStream(IStream kinesisStream)
Kinesis Data Stream to capture item-level changes for the table.
|
Table.Builder |
partitionKey(Attribute partitionKey)
Partition key attribute definition.
|
Table.Builder |
pointInTimeRecovery(Boolean pointInTimeRecovery)
Whether point-in-time recovery is enabled.
|
Table.Builder |
readCapacity(Number readCapacity)
The read capacity for the table.
|
Table.Builder |
removalPolicy(RemovalPolicy removalPolicy)
The removal policy to apply to the DynamoDB Table.
|
Table.Builder |
replicationRegions(List<String> replicationRegions)
Regions where replica tables will be created.
|
Table.Builder |
replicationTimeout(Duration replicationTimeout)
The timeout for a table replication operation in a single region.
|
Table.Builder |
sortKey(Attribute sortKey)
Sort key attribute definition.
|
Table.Builder |
stream(StreamViewType stream)
When an item in the table is modified, StreamViewType determines what information is written to the stream for this table.
|
Table.Builder |
tableClass(TableClass tableClass)
Specify the table class.
|
Table.Builder |
tableName(String tableName)
Enforces a particular physical table name.
|
Table.Builder |
timeToLiveAttribute(String timeToLiveAttribute)
The name of TTL attribute.
|
Table.Builder |
waitForReplicationToFinish(Boolean waitForReplicationToFinish)
Indicates whether CloudFormation stack waits for replication to finish.
|
Table.Builder |
writeCapacity(Number writeCapacity)
The write capacity for the table.
|
@Stability(value=Stable) public static Table.Builder create(software.constructs.Construct scope, String id)
scope - This parameter is required.id - This parameter is required.Table.Builder.@Stability(value=Stable) public Table.Builder partitionKey(Attribute partitionKey)
partitionKey - Partition key attribute definition. This parameter is required.this@Stability(value=Stable) public Table.Builder sortKey(Attribute sortKey)
Default: no sort key
sortKey - Sort key attribute definition. This parameter is required.this@Stability(value=Stable) public Table.Builder billingMode(BillingMode billingMode)
Default: PROVISIONED if `replicationRegions` is not specified, PAY_PER_REQUEST otherwise
billingMode - Specify how you are charged for read and write throughput and how you manage capacity. This parameter is required.this@Stability(value=Stable) public Table.Builder contributorInsightsEnabled(Boolean contributorInsightsEnabled)
Default: false
contributorInsightsEnabled - Whether CloudWatch contributor insights is enabled. This parameter is required.this@Stability(value=Stable) public Table.Builder encryption(TableEncryption encryption)
This property cannot be set if serverSideEncryption is set.
NOTE: if you set this to
CUSTOMER_MANAGEDandencryptionKeyis not specified, the key that the Tablet generates for you will be created with default permissions. If you are using CDKv2, these permissions will be sufficient to enable the key for use with DynamoDB tables. If you are using CDKv1, make sure the feature flag@aws-cdk/aws-kms:defaultKeyPoliciesis set totruein yourcdk.json.
Default: - The table is encrypted with an encryption key managed by DynamoDB, and you are not charged any fee for using it.
encryption - Whether server-side encryption with an AWS managed customer master key is enabled. This parameter is required.this@Stability(value=Stable) public Table.Builder encryptionKey(IKey encryptionKey)
This property can only be set if encryption is set to TableEncryption.CUSTOMER_MANAGED.
Default: - If `encryption` is set to `TableEncryption.CUSTOMER_MANAGED` and this property is undefined, a new KMS key will be created and associated with this table. If `encryption` and this property are both undefined, then the table is encrypted with an encryption key managed by DynamoDB, and you are not charged any fee for using it.
encryptionKey - External KMS key to use for table encryption. This parameter is required.this@Stability(value=Stable) public Table.Builder pointInTimeRecovery(Boolean pointInTimeRecovery)
Default: - point-in-time recovery is disabled
pointInTimeRecovery - Whether point-in-time recovery is enabled. This parameter is required.this@Stability(value=Stable) public Table.Builder readCapacity(Number readCapacity)
Careful if you add Global Secondary Indexes, as those will share the table's provisioned throughput.
Can only be provided if billingMode is Provisioned.
Default: 5
readCapacity - The read capacity for the table. This parameter is required.this@Stability(value=Stable) public Table.Builder removalPolicy(RemovalPolicy removalPolicy)
Default: RemovalPolicy.RETAIN
removalPolicy - The removal policy to apply to the DynamoDB Table. This parameter is required.this@Stability(value=Stable) public Table.Builder replicationRegions(List<String> replicationRegions)
Default: - no replica tables are created
replicationRegions - Regions where replica tables will be created. This parameter is required.this@Stability(value=Stable) public Table.Builder replicationTimeout(Duration replicationTimeout)
Default: Duration.minutes(30)
replicationTimeout - The timeout for a table replication operation in a single region. This parameter is required.this@Stability(value=Stable) public Table.Builder stream(StreamViewType stream)
Default: - streams are disabled unless `replicationRegions` is specified
stream - When an item in the table is modified, StreamViewType determines what information is written to the stream for this table. This parameter is required.this@Stability(value=Stable) public Table.Builder tableClass(TableClass tableClass)
Default: STANDARD
tableClass - Specify the table class. This parameter is required.this@Stability(value=Stable) public Table.Builder timeToLiveAttribute(String timeToLiveAttribute)
Default: - TTL is disabled
timeToLiveAttribute - The name of TTL attribute. This parameter is required.this@Stability(value=Stable) public Table.Builder waitForReplicationToFinish(Boolean waitForReplicationToFinish)
If set to false, the CloudFormation resource will mark the resource as created and replication will be completed asynchronously. This property is ignored if replicationRegions property is not set.
DO NOT UNSET this property if adding/removing multiple replicationRegions in one deployment, as CloudFormation only supports one region replication at a time. CDK overcomes this limitation by waiting for replication to finish before starting new replicationRegion.
Default: true
waitForReplicationToFinish - Indicates whether CloudFormation stack waits for replication to finish. This parameter is required.this@Stability(value=Stable) public Table.Builder writeCapacity(Number writeCapacity)
Careful if you add Global Secondary Indexes, as those will share the table's provisioned throughput.
Can only be provided if billingMode is Provisioned.
Default: 5
writeCapacity - The write capacity for the table. This parameter is required.this@Stability(value=Stable) public Table.Builder kinesisStream(IStream kinesisStream)
Default: - no Kinesis Data Stream
kinesisStream - Kinesis Data Stream to capture item-level changes for the table. This parameter is required.this@Stability(value=Stable) public Table.Builder tableName(String tableName)
Default:
tableName - Enforces a particular physical table name. This parameter is required.thisCopyright © 2022. All rights reserved.