AWS DATABASE SERVICES – DETAILED REVISION NOTES (WITH SCENARIO TIPS)
==============================================================
1. AMAZON RDS (Relational Database Service)
==============================================================
• Fully managed relational database service.
• Supports: MySQL, PostgreSQL, MariaDB, Oracle, SQL Server.
• Automated backups, multi-AZ failover, read replicas.
• Patch management + Monitoring (CloudWatch, Performance Insights).
• Storage autoscaling available.
Sub■services:
• RDS Multi■AZ → For high availability (synchronous replication).
• RDS Read Replicas → For read scaling (asynchronous replication).
• RDS Proxy → Connection pooling for Lambda/microservices.
Use cases:
• Transactional workloads, ERP/CRM apps, OLTP workloads.
Scenario Tips:
• If application needs HA → Choose Multi■AZ.
• If app needs read scaling → Use Read Replicas.
• If sudden traffic spikes (+ serverless apps) → Use RDS Proxy.
• If migrating Oracle/SQL Server to AWS → Consider RDS or Aurora.
==============================================================
2. AMAZON AURORA
==============================================================
• Cloud■optimized, MySQL + PostgreSQL compatible.
• Up to 5x faster than MySQL RDS and 3x faster than PostgreSQL RDS.
• Storage auto-scales up to 128 TB.
• 6 copies of data stored across 3 AZs.
• Supports Serverless V2 and Global Database.
Key Features:
• Aurora Serverless → Auto-scaling DB compute for intermittent workloads.
• Aurora Global DB → Cross-region disaster recovery.
Use cases:
• High-performance, low-latency production workloads.
• SaaS platforms needing massive read scaling.
Scenario Tips:
• If you see “millions of reads per second” → Aurora + Read Replicas.
• If app needs instant failover → Aurora Multi■AZ.
• If unpredictable workloads → Aurora Serverless.
==============================================================
3. AMAZON DYNAMODB
==============================================================
• Fully managed NoSQL key-value + document database.
• Scales to millions of requests per second.
• Single-digit millisecond latency.
• Pricing based on RCU/WCU or On■Demand.
Sub■services:
• DynamoDB Streams → Real-time change capture (CDC).
• DynamoDB Global Tables → Multi-region active-active setup.
• DynamoDB Accelerator (DAX) → In■memory cache for microsecond latency.
• TTL → Auto-expire records.
Use cases:
• Gaming, IoT, shopping carts, session stores.
Scenario Tips:
• If requirement is “low latency, high scalability” → DynamoDB.
• For real■time triggers → Lambda + DynamoDB Streams.
• Multi-region write → Global Tables.
• Caching required → DAX.
==============================================================
4. AMAZON DOCUMENTDB
==============================================================
• Fully managed MongoDB-compatible database.
• Supports JSON workloads at scale.
• Integrates with AWS security (KMS, IAM, VPC).
Use cases:
• Semi■structured data, cataloging systems, CMS systems.
Scenario Tips:
• If user says “MongoDB migration to AWS” → DocumentDB.
==============================================================
5. AMAZON NEPTUNE
==============================================================
• Managed graph database.
• Supports: RDF/SPARQL, OpenCypher, Gremlin graph model.
Use cases:
• Social network graphs, fraud detection, recommendation engines.
Scenario Tips:
• If scenario involves relationships or graph queries → Neptune.
==============================================================
6. AMAZON REDSHIFT
==============================================================
• Cloud data warehouse.
• Used for OLAP analytics at petabyte scale.
• Columnar storage + Massively Parallel Processing (MPP).
• Redshift Spectrum → Query S3 data directly.
• Redshift Serverless → No cluster management.
Use cases:
• BI dashboards, analytics reporting, ML pipelines.
Scenario Tips:
• If question mentions “petabyte scale analytics” → Redshift.
• If they mention “querying S3 without loading data” → Redshift Spectrum.
• For unpredictable workloads → Redshift Serverless.
==============================================================
7. AMAZON ELASTICACHE
==============================================================
• In-memory caching service.
• Redis or Memcached.
• Used to reduce DB load.
Use cases:
• Session caching, leaderboard, pub/sub, high-speed analytics.
Scenario Tips:
• If performance bottleneck → Use ElastiCache (Redis).
==============================================================
8. AMAZON MEMORYDB FOR REDIS
==============================================================
• Durable Redis with multi-AZ transaction safety.
• Ideal for real-time microservices.
Use cases:
• High durability + Redis API compatibility.
Scenario Tips:
• If Redis required + high durability → MemoryDB.
==============================================================
9. AWS DATABASE MIGRATION SERVICE (DMS)
==============================================================
• Used for migrating data from one database to another.
• Supports heterogeneous migrations (Oracle → Aurora, MySQL → DynamoDB).
• Low downtime migration using CDC replication.
Use cases:
• Modernizing legacy databases.
• Real-time replication.
Scenario Tips:
• If requirement says “minimal downtime” → Use DMS.
• If schema conversion required → Use SCT + DMS.
==============================================================
10. AWS SCT (Schema Conversion Tool)
==============================================================
• Converts schema automatically for cross■engine migrations.
• Works with DMS for production cutovers.
Scenario Tips:
• Oracle/SQL Server → Aurora migration → SCT + DMS pair.
==============================================================
11. AMAZON KEYSPACES (Cassandra)
==============================================================
• Managed Cassandra-compatible NoSQL database.
Scenario Tips:
• If migrating Cassandra workloads → Use Keyspaces.
==============================================================
12. QUERY SERVICES: ATHENA, GLUE & LAKE FORMATION
==============================================================
• Athena → Serverless SQL querying directly on S3.
• Glue → ETL transformations + data catalog.
• Lake Formation → Permissions + governance for data lakes.
Scenario Tips:
• For ad■hoc SQL queries on S3 → Athena.
• For ETL workflows → Glue.
• For secure data lakes → Lake Formation.
==============================================================
13. BACKUP, DR, AND REPLICATION FOR DATABASES
==============================================================
• RDS Automated Backups → Retention up to 35 days.
• Aurora Backtracking → Roll back DB in seconds.
• DynamoDB PITR → Point■in-time recovery.
• Cross■region replication → DynamoDB Global Tables, Aurora Global DB.
Scenario Tips:
• If disaster recovery is needed → Cross■region read replicas.
• For “rollback due to wrong update” → PITR or Backtracking.
==============================================================
14. SECURITY FOR DATABASES
==============================================================
• Always use IAM auth when possible (Aurora, RDS MySQL/PostgreSQL).
• Encryption:
- At rest using KMS.
- In transit using TLS.
• Network:
- Place DBs in private subnets.
- Security Groups control access.
Scenario Tips:
• If exam mentions “publicly accessible database” → Answer = **DENY**.
==============================================================
15. COMMON EXAM SCENARIOS & ANSWERS
==============================================================
1■■ Your app reads millions of records per second → **DynamoDB + DAX**
2■■ Need cross■region multi■write DB → **DynamoDB Global Tables**
3■■ Oracle DB migration with minimal downtime → **SCT + DMS**
4■■ Need a high-performance relational database → **Aurora**
5■■ Need sub■millisecond latency for caching → **ElastiCache Redis**
6■■ Need analytics queries on S3 → **Athena**
7■■ Need to store graph relationships → **Neptune**
8■■ Need OLAP warehouse for dashboards → **Redshift**
9■■ Need serverless SQL querying without DB admin → **Athena + Glue**
10■■ Gaming leaderboard with microsecond reads → **DAX or MemoryDB**
==============================================================
END OF NOTES
==============================================================