Question #852
A gaming company runs a real-time leaderboard application backed by an Amazon Aurora PostgreSQL database. The leaderboard data is updated continuously with complex player statistics and high-frequency interactions. The current architecture cannot serve read requests with low latency due to the rapidly changing data and high traffic volume. The company needs a solution to reduce read latency while ensuring data consistency.
Which solution will meet these requirements?
Use Amazon DynamoDB Accelerator (DAX) in front of the Aurora database to cache the frequently changing leaderboard data and reduce read latency.
Enable Amazon Aurora Global Database to replicate the leaderboard data across multiple AWS Regions and reduce latency for global users.
Deploy an Amazon CloudFront distribution configured to cache dynamic leaderboard data directly from the Aurora database at edge locations.
Implement an Amazon ElastiCache for Redis cluster. Modify the application to use a write-through caching strategy and retrieve data from Redis.
Explanation
Option D is correct because:
- ElastiCache for Redis provides an in-memory cache layer, enabling low-latency reads for high-frequency data.
- A write-through caching strategy ensures data consistency by updating the cache immediately after database writes, critical for real-time leaderboards.
Why other options are incorrect:
- A: DAX is only compatible with DynamoDB, not Aurora PostgreSQL.
- B: Aurora Global Database reduces cross-region latency but does not address read latency within the same region for rapidly changing data.
- C: CloudFront caches static content, not dynamic data like real-time leaderboards.
Key Points:
- Use in-memory caching (Redis) for low-latency reads.
- Write-through caching maintains consistency for rapidly changing data.
- Avoid solutions incompatible with the database type (DAX) or designed for static content (CloudFront).
Answer
The correct answer is: D