Closed pradeepnnv closed 9 months ago
Yeah we ran into the same issue with our project as well. Looks like terraform has an extra validation to check the quotas in region before replication. So, we decided to make the dynamodb limits/quotas consistent across the regions by submitting a support request for aws. That should resolve this error.
Marking this issue as stale due to inactivity. This helps our maintainers find and focus on the active issues. If this issue receives no comments in the next 30 days it will automatically be closed. Maintainers can also remove the stale label.
If this issue was automatically closed and you feel this issue should be reopened, we encourage creating a new issue linking back to this one for added context. Thank you!
I'm going to lock this issue because it has been closed for 30 days ⏳. This helps our maintainers find and focus on the active issues. If you have found a problem that seems similar to this, please open a new issue and complete the issue template so we can capture all the details necessary to investigate further.
Creation of Global tables (V2) via Terraform is failing if the TableMaxReadCapacityUnits or TableMaxWriteCapacityUnits are mismatching between replica regions.
Community Note
Terraform CLI and Terraform AWS Provider Version
Terraform: v0.12.31 or v1.0.0 aws: ~> 3.48
Affected Resource(s)
Terraform Configuration Files
Debug Output
https://gist.github.com/pradeepnnv/f431a4be969a5c704d029154e16e357f
Panic Output
Expected Behavior
Dynamodb Global table with 2 replicas in us-east-1 & us-west-2 should be created.
Actual Behavior
Terraform failed with below error.
Table was created only us-east-1 without a replica.
Steps to Reproduce
Raise an AWS Service Limit Request to decrease/increase TableMaxReadCapacityUnits & TableMaxWriteCapacityUnits.
TF_LOG=TRACE TF_LOG_PATH=terraform-debug-output-terraform12.txt terraform12 apply --auto-approve
Important Factoids
TableMaxWriteCapacityUnits & TableMaxReadCapacityUnits values for Dynamodb is different in different regions.
The same example worked when billing mode was switched to PROVISIONED. Below is a working example.