A company is designing the database tier for a new web application. The application stores user session states and profiles. The workload is highly variable and unpredictable, experiencing sudden, irregular traffic spikes of up to read operations per second and write operations per second, followed by several hours of complete inactivity. The company has a strict budget and wants to minimize operational costs while preventing database throttling during traffic spikes. Which database configuration is the most cost-effective for this workload?
- Amazon DynamoDB configured in On-Demand capacity modeAnswer
- BAmazon DynamoDB configured in Provisioned capacity mode with DynamoDB Auto Scaling enabled, setting the minimum capacity to Read Capacity Units (RCUs) and Write Capacity Units (WCUs)
- CAmazon DynamoDB configured in Provisioned capacity mode with a constant provisioned capacity of RCUs and WCUs
- DAn Amazon RDS for MySQL DB instance configured in a Multi-AZ deployment, using Read Replicas in separate Availability Zones as the primary disaster recovery failover targets
Answer
Amazon DynamoDB configured in On-Demand capacity mode
The correct answer is configuring Amazon DynamoDB in On-Demand capacity mode. Because the workload is highly variable and unpredictable with long periods of complete inactivity, paying only for the actual read and write requests aligns perfectly with cost optimization. DynamoDB On-Demand scales instantly to accommodate spikes up to the table's previous peak traffic, ensuring zero throttling without paying for idle capacity.
Step-by-Step Solution
Key Concept
Selecting the cost-optimal database capacity mode for highly unpredictable workloads with idle periods.
Estimated Time:2m 0s