feat: Support warm throughput #106
Open
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Description
This PR adds support for the new warm_throughput configuration option for DynamoDB tables.
Recently, AWS introduced the ability to set warm throughput for On-Demand DynamoDB tables, which allows pre-scaling of partitions to handle anticipated write or read traffic spikes more reliably.
With this change, users of the module can specify a warm_throughput value in WCU/RCU that will be provisioned ahead of time, ensuring their tables are pre-warmed for migration jobs, batch workloads, or expected traffic surges.
Motivation and Context
During high-throughput migrations or batch workloads (e.g., moving data from MySQL to DynamoDB), DynamoDB On-Demand capacity may initially throttle while it scales up.
Warm throughput solves this by proactively allocating partitions to meet the specified throughput baseline.
Breaking Changes
No breaking changes.
The new variable warm_throughput is optional.
If not set, the module behavior remains unchanged and no warm throughput is applied.
How Has This Been Tested?
examples/*
to demonstrate and validate my change(s)examples/*
projectsConverted the table from provisioned with autoscaling to on-demand mode.
Removed autoscaling configuration since it is not applicable with on-demand capacity.
Applied the module with warm_throughput set (e.g., 30000) to verify that the table was created with the warm throughput baseline.
Applied the module with warm_throughput unset to verify that the table was created without warm throughput (default on-demand behavior).
Verified both configurations (with and without warm throughput) were deployed successfully without errors and matched the expected DynamoDB table settings in AWS console.
pre-commit run -a
on my pull request