In this lab, you learn how to build a scalable, real-time leaderboard for a multiplayer game using HAQM Aurora Serverless and HAQM ElastiCache.
HAQM Aurora is a highly performant, cloud-native relational database offering from AWS that offers both MySQL-compatible and PostgreSQL-compatible editions. The Serverless offering of the Aurora database provides on-demand automatic scaling capabilities as well as the Data API, a fast, secure method for accessing your database over HTTP.
HAQM ElastiCache is a fully managed, in-memory data store service from AWS for use cases that require blazing-fast response times. You can use Redis or Memcached with ElastiCache, and it is commonly used for games, FinTech, and other high-speed applications.
HAQM Aurora Serverless and HAQM ElastiCache are both commonly used individually in game applications. You may want to use them together in your game application to get a combination of top-tier speed of an in-memory cache with the reliability and flexibility of a relational database. In this lab, you use HAQM ElastiCache to perform high-volume, low-latency leaderboard checks for different games, and you use HAQM Aurora Serverless to store all historical data and provide redundancy for the leaderboard data.
Some of the key reasons to use both HAQM Aurora Serverless and HAQM ElastiCache for your game application are:
- Performance: Both the Redis and Memcached engines from ElastiCache offer supreme performance with sub-millisecond response times with hundreds of thousands of operations per second.
- Reliability: The Aurora storage layer provides 6-way replication to keep your data safe and protect against data loss.
- Flexibility: Your cache can be designed for specific access patterns that require extreme performance, while your relational database can be used for more flexible access patterns.
AWS Experience: Intermediate
Time to complete: 3 hours
Cost to complete: This tutorial will cost you less than $2 (assuming all services are running for 3 hours)*
Technologies used:
• Active AWS Account**
• Browser: AWS recommends Chrome
• HAQM Aurora
• HAQM ElastiCache
• AWS Secrets Manager
• HAQM Cloud9
• HAQM Cognito
• AWS Lambda
• HAQM API Gateway
• AWS SDK for Node.js
*This estimate assumes you follow the recommended configurations throughout the tutorial and terminate all resources within 3 hours.
**Accounts that have been created within the last 24 hours might not yet have access to the resources required for this project.