DynamoDB Provisioned

  • Provisioned the following
    • RCU (Read capacity units): throughput for read
      • Because of read replicas, we have 3 mode:
        • Strongly Consistent Read
          • we will get consistent read all the time
          • set ConsistentRead parameter to True in API calls (GetItem, BatchGetItem, Query, Scan)
          • Will consume 2 RCU per read
        • Eventually Consistent Read (default):
          • possible we get outdated data if we read right after write
        • Transactional: See DynamoDB Transactions
      • 1 RCU = 1 strongly consistent read or 2 eventually consistent read and can read 4KB
        • For example:
          • 10 strongly consistent reads per second 4 KB : 10 RCUs
          • 16 Evetually consistent reads per seconds with item size 12KB:
            • 8 * 3 = 24 RCU
          • 10 strongly consistent reads with 6 KB per item:
            • 10 * 2 = 20 RCU
            • We round 6KB to 8KB per item
    • WCU (Write capacity units): throughput for writes
      • 1 write per request for an item up to 1 KB in size
      • Have 2 modes:
        • Standard
        • Transactional: DynamoDB Transactions that is single or nothing
        • Example:
          • if have 6 items per second with 4.5KB per item:
            • 6 * 5 = 30 WCU
  • Option to setup auto-scaling of RCU and WCU to meet demand by providing
    • min, max, target utility (%)
  • Throughput can be exceeded temporarily using Burst Capacity
    • If Burst Capacity is exhausted, you will get ProvisionedThroughputExceededException
    • See DynamoDB Throttling