Soru

Zorluk: KolayEdge Caching and Content Delivery for Resilient Architectures

A solutions architect is designing a highly resilient architecture for a web application. The application's static assets are stored in a primary Amazon S3 bucket in one AWS Region. The architect needs to ensure that the assets remain available even if the primary S3 bucket experiences an outage, by failing over to a backup S3 bucket in a different Region with minimal operational complexity. Which configuration will meet these requirements?

  1. Create an Amazon CloudFront origin group with the primary S3 bucket as the primary origin and the backup S3 bucket as the secondary origin.Cevap
  2. B
    Configure an Amazon Route 53 latency routing policy with health checks to fail over traffic directly between the two S3 bucket endpoints.
  3. C
    Create an Amazon CloudFront distribution and set the Time-to-Live (TTL) of all cache behaviors to 0 seconds to bypass caching and query the backup bucket.
  4. D
    Deploy an AWS WAF Web ACL associated with the Amazon CloudFront distribution to inspect requests and redirect them to the backup bucket during an outage.

Cevap

Create an Amazon CloudFront origin group with the primary S3 bucket as the primary origin and the backup S3 bucket as the secondary origin.
Creating a CloudFront origin group is the most efficient and native way to configure failover for static assets. By grouping the primary and secondary S3 buckets, CloudFront automatically reroutes incoming requests to the backup bucket when the primary bucket returns error codes indicating an outage.

Adım Adım Çözüm

1
Identify the primary goal: Establish automatic failover of static content stored in Amazon S3 to a backup bucket in a different Region with minimal operational complexity.
Realized that a global content delivery network like Amazon CloudFront is the best practice for caching static assets and managing origin failover natively.
CloudFront natively supports origin failover using origin groups, which requires no custom code or complex DNS setups.
2
Configure a CloudFront distribution with two S3 bucket origins.
Created a primary origin pointing to the primary S3 bucket and a secondary origin pointing to the backup S3 bucket.
Both origins must be defined in the distribution configuration before they can be grouped.
3
Group the two origins into a CloudFront origin group.
Established an origin group where the primary S3 bucket is the primary origin, and the backup S3 bucket is the secondary origin, specifying the HTTP status codes that trigger failover.
This setup allows CloudFront to automatically redirect requests to the backup bucket if the primary bucket returns status codes like 500, 502, 503, or 504.

Anahtar Kavram

CloudFront Origin Groups and Origin Failover
Bu soruyu puanla