Class TableBaseV2
- All Implemented Interfaces:
IResource,ITable,ITableV2,IResourceWithPolicy,software.amazon.jsii.JsiiSerializable,software.constructs.IConstruct,software.constructs.IDependable
- Direct Known Subclasses:
TableV2
-
Nested Class Summary
Nested classes/interfaces inherited from class software.amazon.jsii.JsiiObject
software.amazon.jsii.JsiiObject.InitializationModeNested classes/interfaces inherited from interface software.constructs.IConstruct
software.constructs.IConstruct.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.IResource
IResource.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.services.iam.IResourceWithPolicy
IResourceWithPolicy.Jsii$DefaultNested classes/interfaces inherited from interface software.amazon.awscdk.services.dynamodb.ITableV2
ITableV2.Jsii$Default -
Constructor Summary
ConstructorsModifierConstructorDescriptionprotectedTableBaseV2(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) protectedTableBaseV2(software.amazon.jsii.JsiiObjectRef objRef) protectedTableBaseV2(software.constructs.Construct scope, String id) protectedTableBaseV2(software.constructs.Construct scope, String id, ResourceProps props) -
Method Summary
Modifier and TypeMethodDescriptionaddToResourcePolicy(PolicyStatement statement) Adds a statement to the resource policy associated with this file system.abstract IKeyThe KMS encryption key for the table.protected abstract Booleanprotected abstract Stringabstract PolicyDocumentThe resource policy for the table.abstract StringThe ARN of the table.abstract StringThe ID of the table.abstract StringThe name of the table.abstract StringThe stream ARN of the table.grant(IGrantable grantee, String... actions) Adds an IAM policy statement associated with this table to an IAM principal's policy.grantFullAccess(IGrantable grantee) Permits an IAM principal to all DynamoDB operations ('dynamodb:*') on this table.grantReadData(IGrantable grantee) Permits an IAM principal all data read operations on this table.grantReadWriteData(IGrantable grantee) Permits an IAM principal to all data read/write operations on this table.grantStream(IGrantable grantee, String... actions) Adds an IAM policy statement associated with this table to an IAM principal's policy.grantStreamRead(IGrantable grantee) Adds an IAM policy statement associated with this table to an IAM principal's policy.grantTableListStreams(IGrantable grantee) Permits an IAM principal to list streams attached to this table.grantWriteData(IGrantable grantee) Permits an IAM principal all data write operations on this table.Return the given named metric for this table.metric(String metricName, MetricOptions props) Return the given named metric for this table.Metric for the conditional check failed requests for this table.Metric for the conditional check failed requests for this table.Metric for the consumed read capacity units for this table.Metric for the consumed read capacity units for this table.Metric for the consumed write capacity units for this table.Metric for the consumed write capacity units for this table.Metric for the successful request latency for this table.Metric for the successful request latency for this table.Deprecated.metricSystemErrors(MetricOptions props) Deprecated.usemetricSystemErrorsForOperations.Metric for the system errors for this table.Metric for the system errors for this table.Deprecated.Do not use this function.Deprecated.Do not use this function.metricThrottledRequestsForOperation(String operation) How many requests are throttled on this table for the given operation.metricThrottledRequestsForOperation(String operation, OperationsMetricOptions props) How many requests are throttled on this table for the given operation.How many requests are throttled on this table.How many requests are throttled on this table.Metric for the user errors for this table.metricUserErrors(MetricOptions props) Metric for the user errors for this table.abstract voidsetResourcePolicy(PolicyDocument value) The resource policy for the table.Methods inherited from class software.amazon.awscdk.Resource
applyRemovalPolicy, generatePhysicalName, getEnv, getPhysicalName, getResourceArnAttribute, getResourceNameAttribute, getStack, isOwnedResource, isResourceMethods inherited from class software.constructs.Construct
getNode, isConstruct, toStringMethods inherited from class software.amazon.jsii.JsiiObject
jsiiAsyncCall, jsiiAsyncCall, jsiiCall, jsiiCall, jsiiGet, jsiiGet, jsiiSet, jsiiStaticCall, jsiiStaticCall, jsiiStaticGet, jsiiStaticGet, jsiiStaticSet, jsiiStaticSetMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, wait, wait, waitMethods inherited from interface software.constructs.IConstruct
getNodeMethods inherited from interface software.amazon.awscdk.IResource
applyRemovalPolicy, getEnv, getStackMethods inherited from interface software.amazon.jsii.JsiiSerializable
$jsii$toJson
-
Constructor Details
-
TableBaseV2
protected TableBaseV2(software.amazon.jsii.JsiiObjectRef objRef) -
TableBaseV2
protected TableBaseV2(software.amazon.jsii.JsiiObject.InitializationMode initializationMode) -
TableBaseV2
@Stability(Stable) protected TableBaseV2(@NotNull software.constructs.Construct scope, @NotNull String id, @Nullable ResourceProps props) - Parameters:
scope- This parameter is required.id- This parameter is required.props-
-
TableBaseV2
@Stability(Stable) protected TableBaseV2(@NotNull software.constructs.Construct scope, @NotNull String id) - Parameters:
scope- This parameter is required.id- This parameter is required.
-
-
Method Details
-
addToResourcePolicy
@Stability(Stable) @NotNull public AddToResourcePolicyResult addToResourcePolicy(@NotNull PolicyStatement statement) Adds a statement to the resource policy associated with this file system.A resource policy will be automatically created upon the first call to
addToResourcePolicy.Note that this does not work with imported file systems.
- Specified by:
addToResourcePolicyin interfaceIResourceWithPolicy- Parameters:
statement- The policy statement to add. This parameter is required.
-
grant
@Stability(Stable) @NotNull public Grant grant(@NotNull IGrantable grantee, @NotNull String... actions) Adds an IAM policy statement associated with this table to an IAM principal's policy.Note: If
encryptionKeyis present, appropriate grants to the key needs to be added separately using thetable.encryptionKey.grant*methods. -
grantFullAccess
Permits an IAM principal to all DynamoDB operations ('dynamodb:*') on this table.Note: Appropriate grants will also be added to the customer-managed KMS keys associated with this table if one was configured.
- Specified by:
grantFullAccessin interfaceITable- Parameters:
grantee- the principal to grant access to. This parameter is required.
-
grantReadData
Permits an IAM principal all data read operations on this table.Actions: BatchGetItem, GetRecords, GetShardIterator, Query, GetItem, Scan, DescribeTable.
Note: Appropriate grants will also be added to the customer-managed KMS keys associated with this table if one was configured.
- Specified by:
grantReadDatain interfaceITable- Parameters:
grantee- the principal to grant access to. This parameter is required.
-
grantReadWriteData
Permits an IAM principal to all data read/write operations on this table.Actions: BatchGetItem, GetRecords, GetShardIterator, Query, GetItem, Scan, BatchWriteItem, PutItem, UpdateItem, DeleteItem, DescribeTable.
Note: Appropriate grants will also be added to the customer-managed KMS keys associated with this table if one was configured.
- Specified by:
grantReadWriteDatain interfaceITable- Parameters:
grantee- the principal to grant access to. This parameter is required.
-
grantStream
@Stability(Stable) @NotNull public Grant grantStream(@NotNull IGrantable grantee, @NotNull String... actions) Adds an IAM policy statement associated with this table to an IAM principal's policy.Note: If
encryptionKeyis present, appropriate grants to the key needs to be added separately using thetable.encryptionKey.grant*methods.- Specified by:
grantStreamin interfaceITable- Parameters:
grantee- the principal (no-op if undefined). This parameter is required.actions- the set of actions to allow (i.e., 'dynamodb:DescribeStream', 'dynamodb:GetRecords', etc.). This parameter is required.
-
grantStreamRead
Adds an IAM policy statement associated with this table to an IAM principal's policy.Actions: DescribeStream, GetRecords, GetShardIterator, ListStreams.
Note: Appropriate grants will also be added to the customer-managed KMS keys associated with this table if one was configured.
- Specified by:
grantStreamReadin interfaceITable- Parameters:
grantee- the principal to grant access to. This parameter is required.
-
grantTableListStreams
Permits an IAM principal to list streams attached to this table.- Specified by:
grantTableListStreamsin interfaceITable- Parameters:
grantee- the principal to grant access to. This parameter is required.
-
grantWriteData
Permits an IAM principal all data write operations on this table.Actions: BatchWriteItem, PutItem, UpdateItem, DeleteItem, DescribeTable.
Note: Appropriate grants will also be added to the customer-managed KMS keys associated with this table if one was configured.
- Specified by:
grantWriteDatain interfaceITable- Parameters:
grantee- the principal to grant access to. This parameter is required.
-
metric
@Stability(Stable) @NotNull public Metric metric(@NotNull String metricName, @Nullable MetricOptions props) Return the given named metric for this table.By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties. -
metric
Return the given named metric for this table.By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties. -
metricConditionalCheckFailedRequests
@Stability(Stable) @NotNull public Metric metricConditionalCheckFailedRequests(@Nullable MetricOptions props) Metric for the conditional check failed requests for this table.By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricConditionalCheckFailedRequestsin interfaceITable- Parameters:
props-
-
metricConditionalCheckFailedRequests
Metric for the conditional check failed requests for this table.By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricConditionalCheckFailedRequestsin interfaceITable
-
metricConsumedReadCapacityUnits
@Stability(Stable) @NotNull public Metric metricConsumedReadCapacityUnits(@Nullable MetricOptions props) Metric for the consumed read capacity units for this table.By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricConsumedReadCapacityUnitsin interfaceITable- Parameters:
props-
-
metricConsumedReadCapacityUnits
Metric for the consumed read capacity units for this table.By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricConsumedReadCapacityUnitsin interfaceITable
-
metricConsumedWriteCapacityUnits
@Stability(Stable) @NotNull public Metric metricConsumedWriteCapacityUnits(@Nullable MetricOptions props) Metric for the consumed write capacity units for this table.By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricConsumedWriteCapacityUnitsin interfaceITable- Parameters:
props-
-
metricConsumedWriteCapacityUnits
Metric for the consumed write capacity units for this table.By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricConsumedWriteCapacityUnitsin interfaceITable
-
metricSuccessfulRequestLatency
@Stability(Stable) @NotNull public Metric metricSuccessfulRequestLatency(@Nullable MetricOptions props) Metric for the successful request latency for this table.By default, the metric will be calculated as an average over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricSuccessfulRequestLatencyin interfaceITable- Parameters:
props-
-
metricSuccessfulRequestLatency
Metric for the successful request latency for this table.By default, the metric will be calculated as an average over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricSuccessfulRequestLatencyin interfaceITable
-
metricSystemErrors
@Stability(Deprecated) @Deprecated @NotNull public Metric metricSystemErrors(@Nullable MetricOptions props) Deprecated.usemetricSystemErrorsForOperations.(deprecated) Metric for the system errors this table.- Parameters:
props-
-
metricSystemErrors
Deprecated.usemetricSystemErrorsForOperations.(deprecated) Metric for the system errors this table. -
metricSystemErrorsForOperations
@Stability(Stable) @NotNull public IMetric metricSystemErrorsForOperations(@Nullable SystemErrorsForOperationsMetricOptions props) Metric for the system errors for this table. This will sum errors across all possible operations.By default, each individual metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricSystemErrorsForOperationsin interfaceITable- Parameters:
props-
-
metricSystemErrorsForOperations
Metric for the system errors for this table. This will sum errors across all possible operations.By default, each individual metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricSystemErrorsForOperationsin interfaceITable
-
metricThrottledRequests
@Stability(Deprecated) @Deprecated @NotNull public Metric metricThrottledRequests(@Nullable MetricOptions props) Deprecated.Do not use this function. It returns an invalid metric. UsemetricThrottledRequestsForOperationinstead.(deprecated) How many requests are throttled on this table.By default, each individual metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricThrottledRequestsin interfaceITable- Parameters:
props-
-
metricThrottledRequests
Deprecated.Do not use this function. It returns an invalid metric. UsemetricThrottledRequestsForOperationinstead.(deprecated) How many requests are throttled on this table.By default, each individual metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricThrottledRequestsin interfaceITable
-
metricThrottledRequestsForOperation
@Stability(Stable) @NotNull public IMetric metricThrottledRequestsForOperation(@NotNull String operation, @Nullable OperationsMetricOptions props) How many requests are throttled on this table for the given operation.By default, the metric will be calculated as an average over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Parameters:
operation- This parameter is required.props-
-
metricThrottledRequestsForOperation
@Stability(Stable) @NotNull public IMetric metricThrottledRequestsForOperation(@NotNull String operation) How many requests are throttled on this table for the given operation.By default, the metric will be calculated as an average over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Parameters:
operation- This parameter is required.
-
metricThrottledRequestsForOperations
@Stability(Stable) @NotNull public IMetric metricThrottledRequestsForOperations(@Nullable OperationsMetricOptions props) How many requests are throttled on this table. This will sum errors across all possible operations.By default, each individual metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricThrottledRequestsForOperationsin interfaceITable- Parameters:
props-
-
metricThrottledRequestsForOperations
How many requests are throttled on this table. This will sum errors across all possible operations.By default, each individual metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricThrottledRequestsForOperationsin interfaceITable
-
metricUserErrors
Metric for the user errors for this table.Note: This metric reports user errors across all the tables in the account and region the table resides in.
By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricUserErrorsin interfaceITable- Parameters:
props-
-
metricUserErrors
Metric for the user errors for this table.Note: This metric reports user errors across all the tables in the account and region the table resides in.
By default, the metric will be calculated as a sum over a period of 5 minutes. You can customize this by using the
statisticandperiodproperties.- Specified by:
metricUserErrorsin interfaceITable
-
getHasIndex
-
getRegion
-
getTableArn
The ARN of the table.- Specified by:
getTableArnin interfaceITable
-
getTableName
The name of the table.- Specified by:
getTableNamein interfaceITable
-
getEncryptionKey
The KMS encryption key for the table.- Specified by:
getEncryptionKeyin interfaceITable
-
getTableId
The ID of the table.- Specified by:
getTableIdin interfaceITableV2
-
getTableStreamArn
The stream ARN of the table.- Specified by:
getTableStreamArnin interfaceITable
-
getResourcePolicy
The resource policy for the table. -
setResourcePolicy
The resource policy for the table.
-
metricSystemErrorsForOperations.