AWS Developer DVA-C02 · Development with AWS Services · medium

The same Amazon DynamoDB table receives 50 standard writes per second of items that are 2.5 KB each, and 15 transactional writes (TransactWriteItems) per second of items that are 1.8 KB each. How many total Write Capacity Units (WCUs) must be provisioned?

Published · Last updated · checked before publication — how we verify questions

Options

  • A180 WCUs (forgetting to double the WCU cost for transactional writes)
  • B152 WCUs (multiplying unrounded fractional kilobytes directly)
  • C210 WCUs (150 WCUs for standard writes plus 60 WCUs for transactions)Correct answer
  • D360 WCUs (doubling both standard and transactional write operations)

Answer: C. 210 WCUs (150 WCUs for standard writes plus 60 WCUs for transactions)

1 WCU supports 1 standard write per second for an item up to 1 KB, whereas transactional writes require 2 WCUs per 1 KB. Each item size is rounded up to the next whole 1 KB: - 50 standard writes of 2.5 KB ($\lceil 2.5 \rceil = 3\text{ KB}$): $50 \times 3 = 150\text{ WCUs}$ - 15 transactional writes of 1.8 KB ($\lceil 1.8 \rceil = 2\text{ KB}$, doubled for transactions): $15 \times 2 \times 2 = 60\text{ WCUs}$ - Total WCUs: $150 + 60 = \mathbf{210\text{ WCUs}}$.

Why the other options are wrong

  • A. 180 WCUs (forgetting to double the WCU cost for transactional writes) — TransactWriteItems requires 2x the WCUs of standard writes (15 * 2 * 2 = 60 WCUs, not 30 WCUs).
  • B. 152 WCUs (multiplying unrounded fractional kilobytes directly) — DynamoDB rounds every write item up to the next whole 1 KB boundary (ceil(2.5) = 3 and ceil(1.8) = 2).
  • D. 360 WCUs (doubling both standard and transactional write operations) — Only transactional writes consume 2 WCUs per 1 KB; standard PutItem calls consume 1 WCU per 1 KB.

All Development with AWS Services questions and the topic overview →

AWS and Amazon Web Services are trademarks of Amazon.com, Inc. PrepIQ Hub is not affiliated with, endorsed by, or sponsored by Amazon Web Services.