Soru

Zorluk: ZorEdge Caching and Content Delivery for Resilient Architectures

A financial services company is launching a global trading dashboard. The application consists of dynamic JSON APIs hosted on Amazon ECS containers behind an Application Load Balancer (ALB) in the us-east-1 Region, and static web assets stored in an Amazon S3 bucket in the same Region. For disaster recovery and high availability, the company has deployed a replica of the ECS application and a replicated S3 bucket in the us-west-2 Region. The company wants to minimize latency for global users and ensure that both static and dynamic requests automatically fail over to the secondary Region with minimal downtime if the primary Region becomes unavailable.

Which combination of actions should a solutions architect take to meet these requirements? (Select two.)

  1. Configure an Amazon CloudFront distribution with two origin groups: one containing the primary and secondary S3 buckets, and another containing the primary and secondary ALBs, with failover criteria set for 5xx status codes.Cevap
  2. Create two cache behaviors in the CloudFront distribution: one for static paths routing to the S3 origin group with caching enabled, and another for dynamic API paths routing to the ALB origin group with caching disabled (TTL set to 0).Cevap
  3. C
    Configure Amazon Route 53 latency-based routing policies pointing directly to the ALBs in both regions, and enable Route 53 health checks to route dynamic API requests during a regional outage.
  4. D
    Deploy AWS Global Accelerator to route dynamic API traffic to the ALB endpoints, and configure Route 53 with failover routing to switch CloudFront static traffic to the backup S3 bucket.
  5. E
    Create a single CloudFront origin group that combines both the primary ALB and the primary S3 bucket, and configure an AWS WAF rule to redirect traffic to the secondary Region.

Cevap

The correct configurations are to set up an Amazon CloudFront distribution with two distinct origin groups (one for S3 buckets and one for Application Load Balancers) and configure two cache behaviors to route static traffic with caching enabled and dynamic API traffic with caching disabled (TTL set to 0) to their respective origin groups.
To achieve both sub-second global latency and high availability with fast failover, the solutions architect should use Amazon CloudFront with origin groups. By configuring separate origin groups for S3 and ALB origins, CloudFront can monitor the primary origin and instantly switch to the secondary origin if a 5xx error status code is returned. Creating separate cache behaviors ensures that static content is cached for performance, while dynamic API calls bypass caching (using a TTL of 0) but still benefit from edge optimizations and origin-level failover.

Adım Adım Çözüm

1
Analyze the requirements for latency minimization and regional failover for both static and dynamic contents.
Identify that CloudFront is required to minimize latency globally and that both static (S3) and dynamic (ALB) resources exist in two regions (primary us-east-1 and secondary us-west-2).
This establishes the scope of the solution which must handle two distinct traffic types and regional disaster recovery.
2
Select the appropriate failover mechanism at the edge layer.
Create two CloudFront origin groups (one for the S3 buckets and one for the ALBs) with us-east-1 as the primary origin and us-west-2 as the failover origin based on 5xx status codes.
CloudFront origin groups provide rapid, CDN-level failover without relying on DNS TTL propagation, meeting the minimal downtime requirement.
3
Configure caching behaviors for the static and dynamic paths.
Create a static cache behavior pointing to the S3 origin group with caching enabled, and a dynamic cache behavior pointing to the ALB origin group with TTL set to 0 to bypass caching.
This optimizes delivery by caching static assets at edge locations while ensuring dynamic API requests are always forwarded to the backend containers.

Anahtar Kavram

Amazon CloudFront Origin Groups and Cache Behaviors
Bu soruyu puanla