Pre-warming a table for on-demand capacity mode - Amazon DynamoDB
Services or capabilities described in Amazon Web Services documentation might vary by Region. To see the differences applicable to the China Regions, see Getting Started with Amazon Web Services in China (PDF).

Pre-warming a table for on-demand capacity mode

For on-demand tables, DynamoDB automatically allocates more capacity as your traffic volume increases. New on-demand tables will be able to sustain up to 4,000 writes per second and 12,000 reads per second. The overall table won't be throttled if the table access is distributed evenly across partitions and the table doesn't exceed twice its previous peak traffic. However, throttling can still occur if the throughput exceeds twice the previous peak within the same 30 minutes.

One solution is to pre-warm the tables to the anticipated peak capacity of the spike. Make sure to check your account limits and confirm that you can reach the desired capacity in provisioned mode. See Throughput default quotas for more information on both account-level and table-level limits.

Note

If you're pre-warming an existing table, or a new table in on-demand mode, start this process at least 24 hours before the anticipated peak. There're certain conditions to the number of switches you can perform in a 24-hour period. For information about these conditions, see Considerations when switching capacity modes.

To pre-warm a table, do the following steps:

  1. Based on the capacity mode of your table, do one of the following steps:

    • To pre-warm a table that's currently in on-demand mode, switch it to provisioned mode.

    • To pre-warm a new table that is in provisioned mode, or has already been in provisioned mode, proceed to the next step without waiting.

  2. Set the table's write throughput to the desired peak value, and keep it there for several minutes. You'll incur cost from this high volume of throughput until you switch back to on-demand.

  3. Switch to on-demand capacity mode. This should allow the table to handle a similar number of requests to the provisioned throughput capacity values.