8

Here are the parameters I have set on the table: enter image description here

And here is what I see for the capacity over time.
enter image description here

Why is it remaining at 25 write units? Shouldn't it go down to 5 write units (the minimum set)?

Scott Decker
  • 4,229
  • 7
  • 24
  • 39

2 Answers2

16

That's because of this note from AWS DynamoDB AutoScaling documentation:

Currently, Auto Scaling does not scale down your provisioned capacity if your table’s consumed capacity becomes zero. As a workaround, you can send requests to the table until Auto Scaling scales down to the minimum capacity, or change the policy to reduce the maximum provisioned capacity to be the same as the minimum provisioned capacity.

In your case, the consumed capacity went down to 0 between 8:00 to 10:00, so the provisioned capacity remained at 25.

Vikdor
  • 23,934
  • 10
  • 61
  • 84
  • 5
    To elaborate on the workaround, you can use a scheduled Lambda function to perform a nominal operation, such as deleting a non-existent key once a minute to ensure auto-scaling will continue to work. This will consume capacity and is likely not for every workload, but I've used it before on a table whose load basically went from 50 write units to 0 at the end of the work day and stayed at 0 till the next morning. By scheduling a nominal write it was able to scale the table down to 1 write unit thereby saving money. – JaredHatfield Dec 20 '17 at 22:36
  • Of course with the recent release of OnDemand capacity, you can now just switch your capacity management scheme to On Demand and the table will pretty much always fit whatever usage pattern you need and you only get billed for actual queries, not predicted queries. – Gareth McCumskey Dec 20 '18 at 08:01
7

Auto Scaling for dynamo DB will now scale down your provisioned capacity if your table’s consumed capacity becomes zero. This eagerly awaited announcement was made on 8th Nov 2018. The official docs are yet to be updated.

Reference

I tested that it works:

enter image description here

marc_s
  • 732,580
  • 175
  • 1,330
  • 1,459
Gary Vernon Grubb
  • 9,695
  • 1
  • 24
  • 27