Question

Difficulty: MediumImproving Database and Caching Efficiency

A software-as-a-service (SaaS) marketing automation platform utilizes an Amazon RDS for PostgreSQL DB instance to support its customer outreach workflows. During large-scale email campaigns, the database experiences high CPU utilization and input/output operations per second (IOPS) bottlenecks, causing delayed delivery actions. A performance analysis reveals that the database bottlenecks are caused by two workloads:

1. Highly frequent read queries to retrieve static email templates that must be highly available and replicated across multiple Availability Zones.
2. High-volume write transactions containing short-lived session tracking tokens that expire after 2 hours and do not require data persistence or replication.

Which of the following actions should the Solutions Architect take to improve database performance and caching efficiency? (Select TWO).

  1. Deploy an Amazon ElastiCache for Redis cluster with Multi-AZ replication to cache the static email templates.Answer
  2. Deploy an Amazon ElastiCache for Memcached cluster to store the transient session tracking tokens.Answer
  3. C
    Deploy an Amazon ElastiCache for Memcached cluster to cache the static email templates, utilizing its multi-AZ replication capabilities.
  4. D
    Provision an Amazon RDS PostgreSQL Read Replica and configure the application to write the transient session tracking tokens directly to it.
  5. E
    Implement Amazon DynamoDB Accelerator (DAX) to cache database queries for both the email templates and session tracking tokens.

Answer

The correct answers are to deploy an Amazon ElastiCache for Redis cluster with Multi-AZ replication to cache the static email templates, and to deploy an Amazon ElastiCache for Memcached cluster to store the transient session tracking tokens.
The correct architecture uses Amazon ElastiCache for Redis to cache static templates because it supports Multi-AZ replication, ensuring high availability. It uses Amazon ElastiCache for Memcached for the transient, short-lived session tracking tokens because Memcached is a lightweight, high-performance, and cost-effective key-value store that does not require replication or durability.

Step-by-Step Solution

1
Analyze the requirements for the static email templates workload.
The templates are read-heavy, require high availability, and must be replicated across Availability Zones.
This determines that the caching engine must support replication and multi-AZ deployments.
2
Select the correct cache engine for the static templates.
Amazon ElastiCache for Redis is selected because it natively supports Multi-AZ replication and persistence.
ElastiCache for Memcached does not support replication, making it unsuitable for this specific workload.
3
Analyze the requirements for the session tracking tokens workload.
The tokens are write-heavy, highly transient (expire in 2 hours), and do not require replication or durability.
This indicates that a simple, high-performance, and cost-effective caching solution without replication overhead is needed.
4
Select the correct cache engine for the session tracking tokens.
Amazon ElastiCache for Memcached is selected because it handles transient data with sub-millisecond latency and has lower cost and management complexity.
Using ElastiCache for Redis for this workload would introduce unnecessary replication overhead and cost since replication is not required.
5
Eliminate database configuration alternatives that violate technical limitations.
RDS Read Replicas are rejected for write workloads, and DynamoDB Accelerator (DAX) is rejected because it does not support RDS PostgreSQL.
Read replicas cannot accept write traffic, and DAX is incompatible with relational databases.

Key Concept

Selecting the appropriate ElastiCache engine (Redis vs Memcached) and offloading strategies based on data persistence, replication, and database engine compatibility.
Rate this question