Class CfnTableMixinProps.Builder
- All Implemented Interfaces:
software.amazon.jsii.Builder<CfnTableMixinProps>
- Enclosing interface:
CfnTableMixinProps
CfnTableMixinProps-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionattributeDefinitions(List<? extends Object> attributeDefinitions) Sets the value ofCfnTableMixinProps.getAttributeDefinitions()attributeDefinitions(IResolvable attributeDefinitions) Sets the value ofCfnTableMixinProps.getAttributeDefinitions()billingMode(String billingMode) Sets the value ofCfnTableMixinProps.getBillingMode()build()Builds the configured instance.contributorInsightsSpecification(CfnTablePropsMixin.ContributorInsightsSpecificationProperty contributorInsightsSpecification) Sets the value ofCfnTableMixinProps.getContributorInsightsSpecification()contributorInsightsSpecification(IResolvable contributorInsightsSpecification) Sets the value ofCfnTableMixinProps.getContributorInsightsSpecification()deletionProtectionEnabled(Boolean deletionProtectionEnabled) Sets the value ofCfnTableMixinProps.getDeletionProtectionEnabled()deletionProtectionEnabled(IResolvable deletionProtectionEnabled) Sets the value ofCfnTableMixinProps.getDeletionProtectionEnabled()globalSecondaryIndexes(List<? extends Object> globalSecondaryIndexes) Sets the value ofCfnTableMixinProps.getGlobalSecondaryIndexes()globalSecondaryIndexes(IResolvable globalSecondaryIndexes) Sets the value ofCfnTableMixinProps.getGlobalSecondaryIndexes()importSourceSpecification(CfnTablePropsMixin.ImportSourceSpecificationProperty importSourceSpecification) Sets the value ofCfnTableMixinProps.getImportSourceSpecification()importSourceSpecification(IResolvable importSourceSpecification) Sets the value ofCfnTableMixinProps.getImportSourceSpecification()Sets the value ofCfnTableMixinProps.getKeySchema()keySchema(IResolvable keySchema) Sets the value ofCfnTableMixinProps.getKeySchema()kinesisStreamSpecification(CfnTablePropsMixin.KinesisStreamSpecificationProperty kinesisStreamSpecification) Sets the value ofCfnTableMixinProps.getKinesisStreamSpecification()kinesisStreamSpecification(IResolvable kinesisStreamSpecification) Sets the value ofCfnTableMixinProps.getKinesisStreamSpecification()localSecondaryIndexes(List<? extends Object> localSecondaryIndexes) Sets the value ofCfnTableMixinProps.getLocalSecondaryIndexes()localSecondaryIndexes(IResolvable localSecondaryIndexes) Sets the value ofCfnTableMixinProps.getLocalSecondaryIndexes()onDemandThroughput(CfnTablePropsMixin.OnDemandThroughputProperty onDemandThroughput) Sets the value ofCfnTableMixinProps.getOnDemandThroughput()onDemandThroughput(IResolvable onDemandThroughput) Sets the value ofCfnTableMixinProps.getOnDemandThroughput()pointInTimeRecoverySpecification(CfnTablePropsMixin.PointInTimeRecoverySpecificationProperty pointInTimeRecoverySpecification) Sets the value ofCfnTableMixinProps.getPointInTimeRecoverySpecification()pointInTimeRecoverySpecification(IResolvable pointInTimeRecoverySpecification) Sets the value ofCfnTableMixinProps.getPointInTimeRecoverySpecification()provisionedThroughput(CfnTablePropsMixin.ProvisionedThroughputProperty provisionedThroughput) Sets the value ofCfnTableMixinProps.getProvisionedThroughput()provisionedThroughput(IResolvable provisionedThroughput) Sets the value ofCfnTableMixinProps.getProvisionedThroughput()resourcePolicy(CfnTablePropsMixin.ResourcePolicyProperty resourcePolicy) Sets the value ofCfnTableMixinProps.getResourcePolicy()resourcePolicy(IResolvable resourcePolicy) Sets the value ofCfnTableMixinProps.getResourcePolicy()sseSpecification(CfnTablePropsMixin.SSESpecificationProperty sseSpecification) Sets the value ofCfnTableMixinProps.getSseSpecification()sseSpecification(IResolvable sseSpecification) Sets the value ofCfnTableMixinProps.getSseSpecification()streamSpecification(CfnTablePropsMixin.StreamSpecificationProperty streamSpecification) Sets the value ofCfnTableMixinProps.getStreamSpecification()streamSpecification(IResolvable streamSpecification) Sets the value ofCfnTableMixinProps.getStreamSpecification()tableClass(String tableClass) Sets the value ofCfnTableMixinProps.getTableClass()Sets the value ofCfnTableMixinProps.getTableName()Sets the value ofCfnTableMixinProps.getTags()timeToLiveSpecification(CfnTablePropsMixin.TimeToLiveSpecificationProperty timeToLiveSpecification) Sets the value ofCfnTableMixinProps.getTimeToLiveSpecification()timeToLiveSpecification(IResolvable timeToLiveSpecification) Sets the value ofCfnTableMixinProps.getTimeToLiveSpecification()warmThroughput(CfnTablePropsMixin.WarmThroughputProperty warmThroughput) Sets the value ofCfnTableMixinProps.getWarmThroughput()warmThroughput(IResolvable warmThroughput) Sets the value ofCfnTableMixinProps.getWarmThroughput()
-
Constructor Details
-
Builder
public Builder()
-
-
Method Details
-
attributeDefinitions
@Stability(Stable) public CfnTableMixinProps.Builder attributeDefinitions(IResolvable attributeDefinitions) Sets the value ofCfnTableMixinProps.getAttributeDefinitions()- Parameters:
attributeDefinitions- A list of attributes that describe the key schema for the table and indexes. This property is required to create a DynamoDB table.Update requires: Some interruptions . Replacement if you edit an existing AttributeDefinition.
- Returns:
this
-
attributeDefinitions
@Stability(Stable) public CfnTableMixinProps.Builder attributeDefinitions(List<? extends Object> attributeDefinitions) Sets the value ofCfnTableMixinProps.getAttributeDefinitions()- Parameters:
attributeDefinitions- A list of attributes that describe the key schema for the table and indexes. This property is required to create a DynamoDB table.Update requires: Some interruptions . Replacement if you edit an existing AttributeDefinition.
- Returns:
this
-
billingMode
Sets the value ofCfnTableMixinProps.getBillingMode()- Parameters:
billingMode- Specify how you are charged for read and write throughput and how you manage capacity. Valid values include:PAY_PER_REQUEST- We recommend usingPAY_PER_REQUESTfor most DynamoDB workloads.PAY_PER_REQUESTsets the billing mode to On-demand capacity mode .PROVISIONED- We recommend usingPROVISIONEDfor steady workloads with predictable growth where capacity requirements can be reliably forecasted.PROVISIONEDsets the billing mode to Provisioned capacity mode .
If not specified, the default is
PROVISIONED.- Returns:
this
-
contributorInsightsSpecification
@Stability(Stable) public CfnTableMixinProps.Builder contributorInsightsSpecification(IResolvable contributorInsightsSpecification) Sets the value ofCfnTableMixinProps.getContributorInsightsSpecification()- Parameters:
contributorInsightsSpecification- The settings used to specify whether to enable CloudWatch Contributor Insights for the table and define which events to monitor.- Returns:
this
-
contributorInsightsSpecification
@Stability(Stable) public CfnTableMixinProps.Builder contributorInsightsSpecification(CfnTablePropsMixin.ContributorInsightsSpecificationProperty contributorInsightsSpecification) Sets the value ofCfnTableMixinProps.getContributorInsightsSpecification()- Parameters:
contributorInsightsSpecification- The settings used to specify whether to enable CloudWatch Contributor Insights for the table and define which events to monitor.- Returns:
this
-
deletionProtectionEnabled
@Stability(Stable) public CfnTableMixinProps.Builder deletionProtectionEnabled(Boolean deletionProtectionEnabled) Sets the value ofCfnTableMixinProps.getDeletionProtectionEnabled()- Parameters:
deletionProtectionEnabled- Determines if a table is protected from deletion. When enabled, the table cannot be deleted by any user or process. This setting is disabled by default. For more information, see Using deletion protection in the Amazon DynamoDB Developer Guide .- Returns:
this
-
deletionProtectionEnabled
@Stability(Stable) public CfnTableMixinProps.Builder deletionProtectionEnabled(IResolvable deletionProtectionEnabled) Sets the value ofCfnTableMixinProps.getDeletionProtectionEnabled()- Parameters:
deletionProtectionEnabled- Determines if a table is protected from deletion. When enabled, the table cannot be deleted by any user or process. This setting is disabled by default. For more information, see Using deletion protection in the Amazon DynamoDB Developer Guide .- Returns:
this
-
globalSecondaryIndexes
@Stability(Stable) public CfnTableMixinProps.Builder globalSecondaryIndexes(IResolvable globalSecondaryIndexes) Sets the value ofCfnTableMixinProps.getGlobalSecondaryIndexes()- Parameters:
globalSecondaryIndexes- Global secondary indexes to be created on the table. You can create up to 20 global secondary indexes.If you update a table to include a new global secondary index, AWS CloudFormation initiates the index creation and then proceeds with the stack update. AWS CloudFormation doesn't wait for the index to complete creation because the backfilling phase can take a long time, depending on the size of the table. You can't use the index or update the table until the index's status is
ACTIVE. You can track its status by using the DynamoDB DescribeTable command.If you add or delete an index during an update, we recommend that you don't update any other resources. If your stack fails to update and is rolled back while adding a new index, you must manually delete the index.
Updates are not supported. The following are exceptions:
- If you update either the contributor insights specification or the provisioned throughput values of global secondary indexes, you can update the table without interruption.
- You can delete or add one global secondary index without interruption. If you do both in the same update (for example, by changing the index's logical ID), the update fails.
- Returns:
this
-
globalSecondaryIndexes
@Stability(Stable) public CfnTableMixinProps.Builder globalSecondaryIndexes(List<? extends Object> globalSecondaryIndexes) Sets the value ofCfnTableMixinProps.getGlobalSecondaryIndexes()- Parameters:
globalSecondaryIndexes- Global secondary indexes to be created on the table. You can create up to 20 global secondary indexes.If you update a table to include a new global secondary index, AWS CloudFormation initiates the index creation and then proceeds with the stack update. AWS CloudFormation doesn't wait for the index to complete creation because the backfilling phase can take a long time, depending on the size of the table. You can't use the index or update the table until the index's status is
ACTIVE. You can track its status by using the DynamoDB DescribeTable command.If you add or delete an index during an update, we recommend that you don't update any other resources. If your stack fails to update and is rolled back while adding a new index, you must manually delete the index.
Updates are not supported. The following are exceptions:
- If you update either the contributor insights specification or the provisioned throughput values of global secondary indexes, you can update the table without interruption.
- You can delete or add one global secondary index without interruption. If you do both in the same update (for example, by changing the index's logical ID), the update fails.
- Returns:
this
-
importSourceSpecification
@Stability(Stable) public CfnTableMixinProps.Builder importSourceSpecification(IResolvable importSourceSpecification) Sets the value ofCfnTableMixinProps.getImportSourceSpecification()- Parameters:
importSourceSpecification- Specifies the properties of data being imported from the S3 bucket source to the" table.If you specify the
ImportSourceSpecificationproperty, and also specify either theStreamSpecification, theTableClassproperty, theDeletionProtectionEnabledproperty, or theWarmThroughputproperty, the IAM entity creating/updating stack must haveUpdateTablepermission.- Returns:
this
-
importSourceSpecification
@Stability(Stable) public CfnTableMixinProps.Builder importSourceSpecification(CfnTablePropsMixin.ImportSourceSpecificationProperty importSourceSpecification) Sets the value ofCfnTableMixinProps.getImportSourceSpecification()- Parameters:
importSourceSpecification- Specifies the properties of data being imported from the S3 bucket source to the" table.If you specify the
ImportSourceSpecificationproperty, and also specify either theStreamSpecification, theTableClassproperty, theDeletionProtectionEnabledproperty, or theWarmThroughputproperty, the IAM entity creating/updating stack must haveUpdateTablepermission.- Returns:
this
-
keySchema
Sets the value ofCfnTableMixinProps.getKeySchema()- Parameters:
keySchema- Specifies the attributes that make up the primary key for the table. The attributes in theKeySchemaproperty must also be defined in theAttributeDefinitionsproperty.- Returns:
this
-
keySchema
Sets the value ofCfnTableMixinProps.getKeySchema()- Parameters:
keySchema- Specifies the attributes that make up the primary key for the table. The attributes in theKeySchemaproperty must also be defined in theAttributeDefinitionsproperty.- Returns:
this
-
kinesisStreamSpecification
@Stability(Stable) public CfnTableMixinProps.Builder kinesisStreamSpecification(IResolvable kinesisStreamSpecification) Sets the value ofCfnTableMixinProps.getKinesisStreamSpecification()- Parameters:
kinesisStreamSpecification- The Kinesis Data Streams configuration for the specified table.- Returns:
this
-
kinesisStreamSpecification
@Stability(Stable) public CfnTableMixinProps.Builder kinesisStreamSpecification(CfnTablePropsMixin.KinesisStreamSpecificationProperty kinesisStreamSpecification) Sets the value ofCfnTableMixinProps.getKinesisStreamSpecification()- Parameters:
kinesisStreamSpecification- The Kinesis Data Streams configuration for the specified table.- Returns:
this
-
localSecondaryIndexes
@Stability(Stable) public CfnTableMixinProps.Builder localSecondaryIndexes(IResolvable localSecondaryIndexes) Sets the value ofCfnTableMixinProps.getLocalSecondaryIndexes()- Parameters:
localSecondaryIndexes- Local secondary indexes to be created on the table. You can create up to 5 local secondary indexes. Each index is scoped to a given hash key value. The size of each hash key can be up to 10 gigabytes.- Returns:
this
-
localSecondaryIndexes
@Stability(Stable) public CfnTableMixinProps.Builder localSecondaryIndexes(List<? extends Object> localSecondaryIndexes) Sets the value ofCfnTableMixinProps.getLocalSecondaryIndexes()- Parameters:
localSecondaryIndexes- Local secondary indexes to be created on the table. You can create up to 5 local secondary indexes. Each index is scoped to a given hash key value. The size of each hash key can be up to 10 gigabytes.- Returns:
this
-
onDemandThroughput
@Stability(Stable) public CfnTableMixinProps.Builder onDemandThroughput(IResolvable onDemandThroughput) Sets the value ofCfnTableMixinProps.getOnDemandThroughput()- Parameters:
onDemandThroughput- Sets the maximum number of read and write units for the specified on-demand table. If you use this property, you must specifyMaxReadRequestUnits,MaxWriteRequestUnits, or both.- Returns:
this
-
onDemandThroughput
@Stability(Stable) public CfnTableMixinProps.Builder onDemandThroughput(CfnTablePropsMixin.OnDemandThroughputProperty onDemandThroughput) Sets the value ofCfnTableMixinProps.getOnDemandThroughput()- Parameters:
onDemandThroughput- Sets the maximum number of read and write units for the specified on-demand table. If you use this property, you must specifyMaxReadRequestUnits,MaxWriteRequestUnits, or both.- Returns:
this
-
pointInTimeRecoverySpecification
@Stability(Stable) public CfnTableMixinProps.Builder pointInTimeRecoverySpecification(IResolvable pointInTimeRecoverySpecification) Sets the value ofCfnTableMixinProps.getPointInTimeRecoverySpecification()- Parameters:
pointInTimeRecoverySpecification- The settings used to enable point in time recovery.- Returns:
this
-
pointInTimeRecoverySpecification
@Stability(Stable) public CfnTableMixinProps.Builder pointInTimeRecoverySpecification(CfnTablePropsMixin.PointInTimeRecoverySpecificationProperty pointInTimeRecoverySpecification) Sets the value ofCfnTableMixinProps.getPointInTimeRecoverySpecification()- Parameters:
pointInTimeRecoverySpecification- The settings used to enable point in time recovery.- Returns:
this
-
provisionedThroughput
@Stability(Stable) public CfnTableMixinProps.Builder provisionedThroughput(IResolvable provisionedThroughput) Sets the value ofCfnTableMixinProps.getProvisionedThroughput()- Parameters:
provisionedThroughput- Throughput for the specified table, which consists of values forReadCapacityUnitsandWriteCapacityUnits. For more information about the contents of a provisioned throughput structure, see Amazon DynamoDB Table ProvisionedThroughput .If you set
BillingModeasPROVISIONED, you must specify this property. If you setBillingModeasPAY_PER_REQUEST, you cannot specify this property.- Returns:
this
-
provisionedThroughput
@Stability(Stable) public CfnTableMixinProps.Builder provisionedThroughput(CfnTablePropsMixin.ProvisionedThroughputProperty provisionedThroughput) Sets the value ofCfnTableMixinProps.getProvisionedThroughput()- Parameters:
provisionedThroughput- Throughput for the specified table, which consists of values forReadCapacityUnitsandWriteCapacityUnits. For more information about the contents of a provisioned throughput structure, see Amazon DynamoDB Table ProvisionedThroughput .If you set
BillingModeasPROVISIONED, you must specify this property. If you setBillingModeasPAY_PER_REQUEST, you cannot specify this property.- Returns:
this
-
resourcePolicy
Sets the value ofCfnTableMixinProps.getResourcePolicy()- Parameters:
resourcePolicy- An AWS resource-based policy document in JSON format that will be attached to the table. When you attach a resource-based policy while creating a table, the policy application is strongly consistent .The maximum size supported for a resource-based policy document is 20 KB. DynamoDB counts whitespaces when calculating the size of a policy against this limit. For a full list of all considerations that apply for resource-based policies, see Resource-based policy considerations .
You need to specify the
CreateTableandPutResourcePolicyIAM actions for authorizing a user to create a table with a resource-based policy.- Returns:
this
-
resourcePolicy
@Stability(Stable) public CfnTableMixinProps.Builder resourcePolicy(CfnTablePropsMixin.ResourcePolicyProperty resourcePolicy) Sets the value ofCfnTableMixinProps.getResourcePolicy()- Parameters:
resourcePolicy- An AWS resource-based policy document in JSON format that will be attached to the table. When you attach a resource-based policy while creating a table, the policy application is strongly consistent .The maximum size supported for a resource-based policy document is 20 KB. DynamoDB counts whitespaces when calculating the size of a policy against this limit. For a full list of all considerations that apply for resource-based policies, see Resource-based policy considerations .
You need to specify the
CreateTableandPutResourcePolicyIAM actions for authorizing a user to create a table with a resource-based policy.- Returns:
this
-
sseSpecification
Sets the value ofCfnTableMixinProps.getSseSpecification()- Parameters:
sseSpecification- Specifies the settings to enable server-side encryption.- Returns:
this
-
sseSpecification
@Stability(Stable) public CfnTableMixinProps.Builder sseSpecification(CfnTablePropsMixin.SSESpecificationProperty sseSpecification) Sets the value ofCfnTableMixinProps.getSseSpecification()- Parameters:
sseSpecification- Specifies the settings to enable server-side encryption.- Returns:
this
-
streamSpecification
@Stability(Stable) public CfnTableMixinProps.Builder streamSpecification(IResolvable streamSpecification) Sets the value ofCfnTableMixinProps.getStreamSpecification()- Parameters:
streamSpecification- The settings for the DynamoDB table stream, which captures changes to items stored in the table. Including this property in your AWS CloudFormation template automatically enables streaming.- Returns:
this
-
streamSpecification
@Stability(Stable) public CfnTableMixinProps.Builder streamSpecification(CfnTablePropsMixin.StreamSpecificationProperty streamSpecification) Sets the value ofCfnTableMixinProps.getStreamSpecification()- Parameters:
streamSpecification- The settings for the DynamoDB table stream, which captures changes to items stored in the table. Including this property in your AWS CloudFormation template automatically enables streaming.- Returns:
this
-
tableClass
Sets the value ofCfnTableMixinProps.getTableClass()- Parameters:
tableClass- The table class of the new table. Valid values areSTANDARDandSTANDARD_INFREQUENT_ACCESS.- Returns:
this
-
tableName
Sets the value ofCfnTableMixinProps.getTableName()- Parameters:
tableName- A name for the table. If you don't specify a name, AWS CloudFormation generates a unique physical ID and uses that ID for the table name. For more information, see Name Type .If you specify a name, you cannot perform updates that require replacement of this resource. You can perform updates that require no or some interruption. If you must replace the resource, specify a new name.
- Returns:
this
-
tags
Sets the value ofCfnTableMixinProps.getTags()- Parameters:
tags- An array of key-value pairs to apply to this resource. For more information, see Tag .- Returns:
this
-
timeToLiveSpecification
@Stability(Stable) public CfnTableMixinProps.Builder timeToLiveSpecification(IResolvable timeToLiveSpecification) Sets the value ofCfnTableMixinProps.getTimeToLiveSpecification()- Parameters:
timeToLiveSpecification- Specifies the Time to Live (TTL) settings for the table.For detailed information about the limits in DynamoDB, see Limits in Amazon DynamoDB in the Amazon DynamoDB Developer Guide.
- Returns:
this
-
timeToLiveSpecification
@Stability(Stable) public CfnTableMixinProps.Builder timeToLiveSpecification(CfnTablePropsMixin.TimeToLiveSpecificationProperty timeToLiveSpecification) Sets the value ofCfnTableMixinProps.getTimeToLiveSpecification()- Parameters:
timeToLiveSpecification- Specifies the Time to Live (TTL) settings for the table.For detailed information about the limits in DynamoDB, see Limits in Amazon DynamoDB in the Amazon DynamoDB Developer Guide.
- Returns:
this
-
warmThroughput
Sets the value ofCfnTableMixinProps.getWarmThroughput()- Parameters:
warmThroughput- Represents the warm throughput (in read units per second and write units per second) for creating a table.- Returns:
this
-
warmThroughput
@Stability(Stable) public CfnTableMixinProps.Builder warmThroughput(CfnTablePropsMixin.WarmThroughputProperty warmThroughput) Sets the value ofCfnTableMixinProps.getWarmThroughput()- Parameters:
warmThroughput- Represents the warm throughput (in read units per second and write units per second) for creating a table.- Returns:
this
-
build
Builds the configured instance.- Specified by:
buildin interfacesoftware.amazon.jsii.Builder<CfnTableMixinProps>- Returns:
- a new instance of
CfnTableMixinProps - Throws:
NullPointerException- if any required attribute was not provided
-