QuestionQ48

VerifiedDesign High-Performing Architectures

A company has developed a new video game as a web application. The application uses a three-tier architecture in a VPC with Amazon RDS for MySQL in the database layer. Several players will compete online at the same time. The game's developers want to:

  • display a top-10 scoreboard in near real time, and
  • provide the ability to stop and restore the game while preserving the current scores.

What should a solutions architect do to meet these requirements?

Explanation

Amazon ElastiCache for Redis is designed for real-time leaderboards by using sorted sets, which automatically maintain unique members in score order and support efficient top-N and rank queries as scores change. AWS documentation specifically identifies gaming leaderboards as a Redis/Valkey use case. Redis-based ElastiCache also supports persistence-oriented durability and backup/restore capabilities needed to preserve scores when the game is stopped and restored, whereas Memcached is only a volatile cache. CloudFront is not appropriate for highly dynamic, low-cacheability leaderboard data, and an RDS read replica only offloads database reads rather than providing an in-memory ranking data structure optimized for concurrent score updates.

Learn more

Community Discussion

No comments yet. Be the first to start the discussion!