Question

Difficulty: HardEdge Caching and Content Delivery for Resilient Architectures

A global e-learning company hosts its interactive quiz application on Amazon EC2 instances behind an Application Load Balancer (ALB) in the us-east-1 Region. To ensure disaster recovery and high availability, the company has deployed a duplicate environment with an ALB in the eu-west-1 Region. The application requires low-latency delivery of dynamic content to global users and must automatically fail over to the secondary Region with minimal downtime if the primary Region experiences an outage. The solution must minimize operational complexity and avoid modifications to client-side DNS configurations. Which solution should the solutions architect implement to meet these requirements?

  1. Configure an Amazon CloudFront distribution and define an origin group containing the us-east-1 ALB as the primary origin and the eu-west-1 ALB as the failover origin. Set failover criteria to include HTTP status codes 500, 502, 503, and 504.Answer
  2. B
    Configure Amazon Route 53 with a latency routing policy pointing to both the us-east-1 ALB and the eu-west-1 ALB. Enable Route 53 health checks on both endpoints to automatically route traffic to the healthy Region during an outage.
  3. C
    Deploy AWS Global Accelerator to route traffic to both ALBs. Configure AWS WAF on the ALBs with a custom rule that blocks incoming traffic to the us-east-1 ALB when it becomes unhealthy, forcing the accelerator to route all requests to the eu-west-1 ALB.
  4. D
    Configure an Amazon CloudFront distribution with the us-east-1 ALB as the primary origin. Configure the cache behavior's default, minimum, and maximum TTL values to 0 seconds. Use Route 53 failover routing policy to update the origin DNS record to point to the eu-west-1 ALB during an outage.

Answer

Configure an Amazon CloudFront distribution with an origin group containing the primary ALB and the backup ALB, configuring failover for HTTP status codes 500, 502, 503, and 504.
The correct solution uses an Amazon CloudFront distribution configured with an Origin Group. This feature allows a primary origin (the Application Load Balancer in us-east-1) and a secondary origin (the Application Load Balancer in eu-west-1) to act in an active-passive setup. When the primary origin returns specific HTTP status codes (such as 500, 502, 503, or 504), CloudFront automatically retries the request against the secondary origin. This failover happens at the edge layer within seconds, preventing user downtime and bypassing client-side DNS caching limitations.

Step-by-Step Solution

1
Identify the primary performance and resilience constraints.
The solution requires low-latency content delivery, automated active-passive regional failover, and minimal operational complexity without modifying client-side DNS settings.
This rules out basic Route 53 failover because client DNS caching (TTL) delays propagation, violating the minimal downtime constraint.
2
Evaluate Amazon CloudFront's native failover capabilities.
CloudFront supports Origin Groups, which allow designating a primary origin and a failover origin.
Edge-level failover avoids DNS propagation delays, routing requests directly to the backup region if the primary region's ALB fails.
3
Define the failover criteria.
Specify HTTP status codes (500, 502, 503, 504) that represent origin unavailability or server-side failure.
This guarantees that if the primary ALB or its backend EC2 instances fail, CloudFront immediately redirects the user request to the secondary ALB in eu-west-1.

Key Concept

CloudFront Origin Groups and Failover Configuration
Estimated Time:2m 30s
Rate this question