MemoryDB
💡 Definition
Amazon MemoryDB for Redis is a Redis-compatible, durable, in-memory database service that delivers ultra-fast performance.
🔑 Key Concepts
- In-Memory Speed: Microsecond read and single-digit millisecond write latency.
- Durability: Unlike ElastiCache (which is a cache), MemoryDB persists data across Multi-AZs using a distributed transactional log.
- Redis Compatible: Works with existing Redis tools and code.
⚙️ How it Works
It acts as a primary database (not just a cache). It stores data in memory for speed but also writes to a durable transaction log across multiple AZs to ensure data is not lost if a node fails.
🎯 Use Cases
- Microservices: Backend for high-performance microservices.
- Gaming: Leaderboards, player state.
- IoT: Real-time device data.
💰 Pricing Model
- Data stored: Charged per GB-month.
- Data written: Charged per GB written.
📝 Exam Tips (CLF-C02)
- Keyword: "Redis-compatible, durable, in-memory database".
- Difference from ElastiCache: Durability (MemoryDB is a primary DB, ElastiCache is a cache/ephemeral).
See Also: * ElastiCache * DynamoDB