Opening Scenario
You're designing the data layer for a new service. The engineering manager asks: "Should we use DynamoDB or RDS?" You've heard that DynamoDB is fast and scalable, and that RDS is "just Postgres." But that framing misses the point. The right answer depends entirely on your access patterns, consistency requirements, and the shape of your data. Let's reason through it.
Question Progression
1. What does your query look like?
Question: Before choosing a database, what's the single most important question to answer about your data?
Reasoning: Both databases store data. Both can handle millions of records. The critical difference is how you can query them.
Answer: The most important question is: do you know your access patterns upfront, and are they simple and predictable?
- DynamoDB is a key-value and document store. You retrieve items by a primary key (partition key, optionally with a sort key). Secondary indexes let…
In the full tutorial
- Decision Summary
- When to Reach for Each