Join GitHub today
GitHub is home to over 40 million developers working together to host and review code, manage projects, and build software together.Sign up
dynamodb_table support for On-Demand billing #56923
A new billing mode was added to DynamoDB back in Nov, 2018 called On-Demand which acts as an alternative to setting RCU and WCU values. This feature is already supported in Boto 3 with the BillingMode attribute. This feature request is to implement the On-Demand billing option in the dynamodb_table module.
Note that there's already an Issue opened for this which wasn't filled in correctly: #54963. Instead of letting that issue languish any further, I suggest closing it in favor of this one.
Another link explaining how the new pricing model works: https://aws.amazon.com/dynamodb/pricing/
I'd suggest adding a 'billing_mode' parameter to the module which can hold a value of either 'provisioned' or 'pay_per_request' to reflect Boto3 values. The 'indexes' parameter will also need to be updated since GSI's can also support on-demand billing. 'billing_mode' should probably default to 'pay_per_request' since that seems like a more popular and generic setting unless you know exactly how many RCU/WCU's you want; This is the reason AWS added this mode, of course. To support backwards compatibility with existing tasks, if 'read_capacity' and 'write_capacity' are set then the 'billing_mode' would switch to 'provisioned' automatically.
- dynamodb_table: name: my-table region: us-east-1 hash_key_name: id hash_key_type: STRING range_key_name: create_time range_key_type: NUMBER billing_mode: PAY_PER_REQUEST tags: tag_name: tag_value
Files identified in the description:
If these files are inaccurate, please update the