Soru

Zorluk: OrtaHigh-Performing Content Delivery and Caching Solutions

A retail company operates a popular online store on AWS. The application's product catalog is stored in an Amazon RDS for MySQL database. During peak shopping events, the database experiences high read latency and CPU utilization near 100% due to repetitive read queries for identical product details. The product data changes occasionally, and the application must serve the most up-to-date data. The company wants to implement a high-performing caching solution to reduce the database load and minimize response time. Which solution should a solutions architect recommend to meet these requirements?

  1. Deploy an Amazon ElastiCache for Redis cluster. Configure the application to use a cache-aside strategy to load data into the cache on a read miss, and write data to both the database and the cache on updates.Cevap
  2. B
    Configure an Amazon CloudFront distribution in front of the application. Create a cache behavior for the API endpoints serving the product catalog and set the Minimum, Default, and Maximum TTLs to 0 to ensure the catalog data is always fresh.
  3. C
    Migrate the product catalog to an Amazon DynamoDB table. Configure the table to use Provisioned Capacity Mode with static, high read capacity units to handle the peak request rate at all times.
  4. D
    Configure an Amazon Route 53 latency routing policy to distribute read query traffic directly to Amazon RDS Read Replicas deployed across multiple AWS Regions.

Cevap

Deploy an Amazon ElastiCache for Redis cluster. Configure the application to use a cache-aside strategy to load data into the cache on a read miss, and write data to both the database and the cache on updates.
Deploying Amazon ElastiCache in front of the relational database is the standard best practice for accelerating read-heavy database queries. The cache-aside strategy ensures that frequently queried product details are stored in memory, providing sub-millisecond response times. Writing updates to the cache when the database is updated ensures that inventory changes are immediately reflected, satisfying the requirement to serve the most up-to-date data.

Adım Adım Çözüm

1
Analyze the workload characteristics and requirements.
The workload is read-heavy, experiences high latency during spikes, contains repetitive reads of identical data, and requires real-time data consistency.
This helps identify the appropriate caching layer and data synchronization strategy.
2
Select the correct caching technology.
Amazon ElastiCache for Redis is selected because it is designed for database query caching and supports complex data types and replication.
CloudFront caches static web assets at the edge, whereas ElastiCache caches database query results closer to the application logic.
3
Determine the cache synchronization strategy.
Implement cache-aside to load data into ElastiCache only when needed, and update the cache when database records are modified.
This keeps the database load low while ensuring data updates are reflected in real-time.

Anahtar Kavram

Database query caching using Amazon ElastiCache to offload read traffic from Amazon RDS and reduce application latency.
Bu soruyu puanla