Managed relational databases: MySQL, PostgreSQL, MariaDB, Oracle, SQL Server.
MySQL and PostgreSQL compatible, 5x MySQL and 3x PostgreSQL performance.
Fully managed NoSQL key-value and document database.
Managed in-memory caching.
| Feature | Redis | Memcached |
|---|---|---|
| Persistence | Yes | No |
| Replication | Yes (Multi-AZ) | No |
| Data Types | Rich (strings, lists, sets, hashes) | Simple (strings) |
| Pub/Sub | Yes | No |
| Multi-threaded | No (single-threaded) | Yes |
Caching Strategies:
| Requirement | Recommended Engine |
|---|---|
| MySQL/PostgreSQL compatible, high performance | Aurora |
| Oracle or SQL Server | RDS |
| Key-value, millisecond latency, serverless | DynamoDB |
| Graph data, relationships | Neptune |
| Time-series data | Timestream |
| Ledger, immutable records | QLDB |
| Wide-column (Cassandra compatible) | Keyspaces |
Create an ElastiCache Redis cluster and test basic caching operations.
20 minutes
Step 1: Create a cache subnet group
aws elasticache create-cache-subnet-group \
--cache-subnet-group-name saa-cache-subnet \
--cache-subnet-group-description "SAA Study Cache Subnet" \
--subnet-ids <subnet-1> <subnet-2>
Step 2: Create a Redis cluster
aws elasticache create-cache-cluster \
--cache-cluster-id saa-redis-cluster \
--cache-node-type cache.t3.micro \
--engine redis \
--num-cache-nodes 1 \
--cache-subnet-group-name saa-cache-subnet
Step 3: Check cluster status
aws elasticache describe-cache-clusters \
--cache-cluster-id saa-redis-cluster \
--show-cache-node-info \
--query 'CacheClusters[0].[CacheClusterStatus,CacheNodes[0].Endpoint]'
aws elasticache delete-cache-cluster --cache-cluster-id saa-redis-cluster
# Wait for deletion
aws elasticache delete-cache-subnet-group --cache-subnet-group-name saa-cache-subnet
| # | Question | Answer |
|---|---|---|
| 1 | How many read replicas can Aurora have? | Up to 15 |
| 2 | What is Aurora Serverless v2 minimum ACU? | 0.5 ACU |
| 3 | What is DynamoDB DAX? | In-memory cache for DynamoDB with microsecond latency |
| 4 | What is the difference between Redis and Memcached? | Redis: persistence, replication, rich data types. Memcached: simple, multi-threaded, no persistence. |
| 5 | What is Lazy Loading caching strategy? | Load data into cache only on cache miss. Stale data possible. |
| 6 | What is Write-Through caching? | Write to cache and DB simultaneously. No stale data. |
| 7 | What is DynamoDB On-Demand mode? | Pay per request, auto-scales, no capacity planning needed |
| 8 | What is Aurora Global Database RPO? | 1 second |
| 9 | What database is best for graph data? | Amazon Neptune |
| 10 | How many RDS read replicas (non-Aurora)? | Up to 5 |
A company has a read-heavy application with a MySQL database. They need to improve read performance and achieve 5x better throughput than standard MySQL. Which solution is best?
Correct: B
Aurora MySQL provides 5x the throughput of standard MySQL and supports up to 15 read replicas with sub-10ms lag. RDS MySQL is standard performance. DynamoDB is NoSQL, not a drop-in MySQL replacement. ElastiCache is a cache, not a database replacement.
Domain: 3 — Design High-Performing Architectures Task: 3.3
A company needs a database for a high-traffic e-commerce application that requires single-digit millisecond latency for key-value lookups. The traffic is unpredictable. Which solution is most appropriate?
Correct: C
DynamoDB provides single-digit millisecond latency for key-value lookups. On-Demand capacity mode handles unpredictable traffic without capacity planning. RDS and Aurora are relational and have higher latency for key-value patterns. Memcached is a cache, not a primary database.
Domain: 3 — Design High-Performing Architectures Task: 3.3
A company wants to reduce database query latency from milliseconds to microseconds for frequently accessed data. The data is stored in DynamoDB. Which service should they add?
Correct: B
DAX is an in-memory cache specifically designed for DynamoDB, providing microsecond read latency. It is a drop-in replacement requiring minimal code changes. ElastiCache works but requires more application changes. CloudFront caches HTTP responses, not database queries. RDS Proxy is for RDS, not DynamoDB.
Domain: 3 — Design High-Performing Architectures Task: 3.3
A company needs to cache session data for a web application. The cache must support replication for high availability and complex data structures. Which ElastiCache engine should they choose?
Correct: B
Redis supports replication (Multi-AZ), persistence, and rich data structures (hashes, lists, sets). Memcached does not support replication or complex data types. While DynamoDB can store sessions, ElastiCache Redis provides lower latency for session caching.
Domain: 3 — Design High-Performing Architectures Task: 3.3
A company has a variable workload that ranges from 0 to thousands of requests per second. They need a relational database that automatically scales capacity. Which solution is best?
Correct: B
Aurora Serverless v2 automatically scales compute capacity in fine-grained increments (0.5 ACU) based on demand. It is relational (MySQL/PostgreSQL compatible) and handles variable workloads. RDS Auto Scaling only scales storage, not compute. DynamoDB is NoSQL. Read replicas require manual management.
Domain: 3 — Design High-Performing Architectures Task: 3.3