UpdateTable
Modifies the retention duration of the memory store and magnetic store for your Timestream table. Note that the change in retention duration takes effect immediately. For example, if the retention period of the memory store was initially set to 2 hours and then changed to 24 hours, the memory store will be capable of holding 24 hours of data, but will be populated with 24 hours of data 22 hours after this change was made. Timestream does not retrieve data from the magnetic store to populate the memory store.
See code sample for details.
Request Syntax
{
"DatabaseName": "string
",
"MagneticStoreWriteProperties": {
"EnableMagneticStoreWrites": boolean
,
"MagneticStoreRejectedDataLocation": {
"S3Configuration": {
"BucketName": "string
",
"EncryptionOption": "string
",
"KmsKeyId": "string
",
"ObjectKeyPrefix": "string
"
}
}
},
"RetentionProperties": {
"MagneticStoreRetentionPeriodInDays": number
,
"MemoryStoreRetentionPeriodInHours": number
},
"Schema": {
"CompositePartitionKey": [
{
"EnforcementInRecord": "string
",
"Name": "string
",
"Type": "string
"
}
]
},
"TableName": "string
"
}
Request Parameters
For information about the parameters that are common to all actions, see Common Parameters.
The request accepts the following data in JSON format.
- DatabaseName
-
The name of the Timestream database.
Type: String
Length Constraints: Minimum length of 3. Maximum length of 256.
Required: Yes
- MagneticStoreWriteProperties
-
Contains properties to set on the table when enabling magnetic store writes.
Type: MagneticStoreWriteProperties object
Required: No
- RetentionProperties
-
The retention duration of the memory store and the magnetic store.
Type: RetentionProperties object
Required: No
- Schema
-
The schema of the table.
Type: Schema object
Required: No
- TableName
-
The name of the Timestream table.
Type: String
Length Constraints: Minimum length of 3. Maximum length of 256.
Required: Yes
Response Syntax
{
"Table": {
"Arn": "string",
"CreationTime": number,
"DatabaseName": "string",
"LastUpdatedTime": number,
"MagneticStoreWriteProperties": {
"EnableMagneticStoreWrites": boolean,
"MagneticStoreRejectedDataLocation": {
"S3Configuration": {
"BucketName": "string",
"EncryptionOption": "string",
"KmsKeyId": "string",
"ObjectKeyPrefix": "string"
}
}
},
"RetentionProperties": {
"MagneticStoreRetentionPeriodInDays": number,
"MemoryStoreRetentionPeriodInHours": number
},
"Schema": {
"CompositePartitionKey": [
{
"EnforcementInRecord": "string",
"Name": "string",
"Type": "string"
}
]
},
"TableName": "string",
"TableStatus": "string"
}
}
Response Elements
If the action is successful, the service sends back an HTTP 200 response.
The following data is returned in JSON format by the service.
Errors
For information about the errors that are common to all actions, see Common Errors.
- AccessDeniedException
-
You are not authorized to perform this action.
HTTP Status Code: 400
- InternalServerException
-
Timestream was unable to fully process this request because of an internal server error.
HTTP Status Code: 500
- InvalidEndpointException
-
The requested endpoint was not valid.
HTTP Status Code: 400
- ResourceNotFoundException
-
The operation tried to access a nonexistent resource. The resource might not be specified correctly, or its status might not be ACTIVE.
HTTP Status Code: 400
- ThrottlingException
-
Too many requests were made by a user and they exceeded the service quotas. The request was throttled.
HTTP Status Code: 400
- ValidationException
-
An invalid or malformed request.
HTTP Status Code: 400
See Also
For more information about using this API in one of the language-specific AWS SDKs, see the following: