What is Amazon DynamoDB?

Why Interviewers Ask This

This question tests conceptual clarity. Interviewers want to hear a precise, confident definition before moving to more complex AWS / Cloud Computing topics. It also reveals how well you can explain technical ideas to non-experts.

Answer

Amazon DynamoDB is a fully managed, serverless NoSQL database that delivers single-digit millisecond performance at any scale. No server management, built-in security, backup, restore, and in-memory caching. Key concepts: (1) Tables: collection of items (no fixed schema); (2) Items: equivalent to rows — each has a primary key; (3) Attributes: equivalent to columns — schema-less (items can have different attributes); (4) Primary key: Partition key only (simple) or Partition key + Sort key (composite). Must be unique per table; (5) Partition key: hashed to determine which partition stores the item. High cardinality key for even distribution; (6) Sort key: enables range queries and sorting within a partition. Capacity modes: Provisioned (specify RCU/WCU — Reserved and Savings Plans available); On-Demand (pay per request — no capacity planning). Indexes: Global Secondary Index (GSI — different partition key, can be any attribute, eventually consistent); Local Secondary Index (LSI — same partition key, different sort key, created at table creation). DynamoDB Streams: ordered stream of item changes — trigger Lambda for CDC patterns. Transactions: TransactWriteItems and TransactGetItems — ACID across up to 100 items in 10 tables. Global Tables: multi-region, active-active replication. DAX (DynamoDB Accelerator): in-memory cache, sub-millisecond reads. Best for: key-value access patterns, session storage, shopping carts, IoT, gaming leaderboards. Not for: complex queries with JOINs, ad-hoc analytics.

Pro Tip

Demonstrate both theoretical understanding and practical experience. Say what it is, then give an example of how you actually used it in a AWS / Cloud Computing codebase.