clarkie / dynogels

DynamoDB data mapper for node.js. Originally forked from https://github.com/ryanfitz/vogels

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Enable On-Demand Billing Mode

aneilbaboo opened this issue · comments

In November, AWS released On-Demand mode: https://aws.amazon.com/blogs/aws/amazon-dynamodb-on-demand-no-capacity-planning-and-pay-per-request-pricing/

It would be great to have support for this: It's enabled by setting a new BillingMode attribute to 'PAY_PER_REQUEST' in the AWS table configuration JSON.

Maybe something like:

var Account = dynogels.define('MyTable', {
  hashKey : 'id',
  billingMode: 'PAY_PER_REQUEST', // default is 'PROVISIONED'
  schema : {
   id: ...
  }
});