Question 20
Domain 3: Resilient Cloud SolutionsA company used a lift and shift strategy to migrate a workload to AWS. The company has an Auto Scaling group of Amazon EC2 instances. Each EC2 instance runs a web application, a database, and a Redis cache. Users are experiencing large variations in the web application's response times. Requests to the web application go to a single EC2 instance that is under significant load. The company wants to separate the application components to improve availability and performance. Which solution will meet these requirements?
Correct answer: D
Explanation
An Application Load Balancer distributes web requests across multiple EC2 instances, so traffic no longer goes to “a single EC2 instance that is under significant load.” Moving the database to Amazon Aurora with “Multi-AZ deployment” improves availability, and Amazon ElastiCache for Redis separates the cache from the application server to improve performance.
Why each option is right or wrong
A. Create a Network Load Balancer and an Auto Scaling group for the web application. Migrate the database to an Amazon Aurora Serverless database. Create an Application Load Balancer and an Auto Scaling group for the Redis cache.
Network Load Balancer fits lower-level traffic; Redis should use ElastiCache, not EC2 Auto Scaling.
B. Create an Application Load Balancer and an Auto Scaling group for the web application. Migrate the database to an Amazon Aurora database that has a Multi-AZ deployment. Create a Network Load Balancer and an Auto Scaling group in a single Availability Zone for the Redis cache.
Redis in a single Availability Zone reduces availability and NLB is not the usual web-tier choice.
C. Create a Network Load Balancer and an Auto Scaling group for the web application. Migrate the database to an Amazon Aurora Serverless database. Create an Amazon ElastiCache (Redis OSS) cluster for the cache. Create a target group that has a DNS target type that contains the ElastiCache (Redis OSS) cluster hostname.
ElastiCache is appropriate, but routing load balancer targets to cache DNS is the wrong architecture.
D. Create an Application Load Balancer and an Auto Scaling group for the web application. Migrate the database to an Amazon Aurora database that has a Multi-AZ deployment. Create an Amazon ElastiCache (Redis OSS) cluster for the cache.
The workload is currently collapsed onto one EC2 host, so the web tier is a single point of contention; an Application Load Balancer is the AWS service that distributes HTTP/HTTPS traffic across registered targets in multiple Availability Zones, removing the “one instance gets all requests” bottleneck. Separating the database onto Amazon Aurora with Multi-AZ uses a managed relational service with synchronous replication and automatic failover across at least 2 AZs, which is the availability improvement the question asks for, while ElastiCache for Redis offloads cache reads/writes from the instance so the application server is no longer competing with the cache for CPU, memory, and disk.