-
Notifications
You must be signed in to change notification settings - Fork 9.3k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
resource/aws_dynamodb_table: Improve update handling
References: * #7447 * #5471 Changes: * tests/resource/aws_dynamodb_table: Ensure acceptance testing covers all scenarios involving billing_mode updates with and without global secondary indexes * tests/resource/aws_dynamodb_table: Update testAccCheckDynamoDbTableHasBilling_Provisioned to handle missing BillingModeSummary * resource/aws_dynamodb_table: Consolidate UpdateTable calls to prevent error when switching billing_mode from PAY_PER_REQUEST to PROVISIONED when global secondary indexes are present and reduce API traffic * resource/aws_dynamodb_table: Utilize customizable update timeout in global secondary index update operations * resource/aws_dynamodb_table: Increase default update timeout from 10 minutes to 60 minutes since even 30 minutes can trigger timeouts with no table data Previous output from acceptance testing: ``` --- FAIL: TestAccAWSDynamoDbTable_BillingMode_GSI_PayPerRequestToProvisioned (142.20s) testing.go:538: Step 1 error: Error applying: 1 error occurred: * aws_dynamodb_table.basic-dynamodb-table: 1 error occurred: * aws_dynamodb_table.basic-dynamodb-table: Error updating DynamoDB Table (TerraformTestTable--132444596974972667) billing mode: ValidationException: One or more parameter values were invalid: ProvisionedThroughput must be specified for index: TestTableGSI ``` Output from acceptance testing: ``` --- PASS: TestAccAWSDynamoDbTable_attributeUpdate (441.98s) --- PASS: TestAccAWSDynamoDbTable_attributeUpdateValidation (3.00s) --- PASS: TestAccAWSDynamoDbTable_basic (108.09s) --- PASS: TestAccAWSDynamoDbTable_BillingMode_GSI_PayPerRequestToProvisioned (158.73s) --- PASS: TestAccAWSDynamoDbTable_BillingMode_GSI_ProvisionedToPayPerRequest (1027.81s) --- PASS: TestAccAWSDynamoDbTable_BillingMode_PayPerRequestToProvisioned (127.56s) --- PASS: TestAccAWSDynamoDbTable_BillingMode_ProvisionedToPayPerRequest (917.15s) --- PASS: TestAccAWSDynamoDbTable_disappears (17.37s) --- PASS: TestAccAWSDynamoDbTable_disappears_PayPerRequestWithGSI (181.60s) --- PASS: TestAccAWSDynamoDbTable_enablePitr (286.99s) --- PASS: TestAccAWSDynamoDbTable_encryption (222.91s) --- PASS: TestAccAWSDynamoDbTable_extended (286.03s) --- PASS: TestAccAWSDynamoDbTable_gsiUpdateCapacity (178.27s) --- PASS: TestAccAWSDynamoDbTable_gsiUpdateNonKeyAttributes (416.57s) --- PASS: TestAccAWSDynamoDbTable_gsiUpdateOtherAttributes (661.25s) --- PASS: TestAccAWSDynamoDbTable_importBasic (137.95s) --- PASS: TestAccAWSDynamoDbTable_importTags (170.40s) --- PASS: TestAccAWSDynamoDbTable_importTimeToLive (138.59s) --- PASS: TestAccAWSDynamoDbTable_streamSpecification (127.55s) --- PASS: TestAccAWSDynamoDbTable_streamSpecificationValidation (1.05s) --- PASS: TestAccAWSDynamoDbTable_tags (144.68s) --- PASS: TestAccAWSDynamoDbTable_ttl (139.86s) ```
- Loading branch information
Showing
3 changed files
with
206 additions
and
117 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.