Skip to the page

Foundations: IAM, storage, databases, monitoring · mid

RDS, Aurora and DynamoDB

RDS runs managed Postgres or MySQL (backups, patching, Multi-AZ failover, read replicas), Aurora is AWS's compatible engine with storage spread across AZs and a serverless option, and DynamoDB is a key-value and document store that scales almost without limit if you design keys around your access patterns.

The notes

What you must know

  • RDS: AWS handles backups, point-in-time restore, patching. Multi-AZ = a standby in another AZ for automatic failover (high availability). Read replicas = extra read capacity (scaling), with some replication lag.
  • Aurora (Postgres or MySQL compatible): storage replicated across three AZs, fast failover, up to 15 replicas; Aurora Serverless v2 scales capacity automatically and can now scale to zero when idle.
  • DynamoDB: tables with a partition key (and optional sort key); single-digit-millisecond reads at any scale; on-demand or provisioned capacity; secondary indexes (GSIs) for other access patterns; design keys from queries first; limited ad-hoc querying and joins.
  • ElastiCache (Redis/Valkey/Memcached) for caching and sessions.
  • Connections: Lambda + RDS needs RDS Proxy (connection pooling).
  • Choose: relational data, transactions and reporting -> RDS/Aurora Postgres; huge scale with simple key lookups (sessions, carts, event logs) -> DynamoDB.

The red pen

Common traps: mistake → fix

  • Mistake: Multi-AZ gives read scaling

    Fix: the standby does not serve reads; use read replicas for that.

  • Mistake: DynamoDB is a drop-in replacement for SQL

    Fix: without designing keys for your queries you end up scanning the table.

Easy to hard

Questions interviewers ask, easy to hard

  1. RDS vs DynamoDB: how do you choose?
  2. Multi-AZ vs read replicas?
  3. What is a partition key, and what is a hot partition?
  4. How do you connect Lambda functions to RDS safely?

Your first interview is free

Sign up and start with a 15-minute interview with the full report, and an English conversation. No card needed.

Start your free interview