A company hosts a global media application that distributes static images from an Amazon S3 bucket. To minimize latency and protect the application from origin server failures, a solutions architect is implementing an Amazon CloudFront distribution. The architecture must automatically redirect traffic to a backup S3 bucket in a different AWS Region if the primary S3 bucket returns an HTTP 502 or 504 error. Which combination of actions should the solutions architect perform to meet these resiliency requirements? (Select TWO.)
- Create a CloudFront origin group containing both the primary and backup S3 buckets as origins, designating the primary bucket as primary.Cevap
- Configure the CloudFront distribution's cache behavior to direct requests to the newly created origin group.Cevap
- CConfigure an Amazon Route 53 failover routing policy that points to the primary and backup S3 bucket endpoints, and set the CloudFront origin to this Route 53 record.
- DDeploy an AWS WAF web ACL associated with the CloudFront distribution, and configure a custom rule to intercept 5xx errors and redirect requests to the backup S3 bucket.
- ESet the Minimum TTL, Default TTL, and Maximum TTL to 0 in the cache behavior settings to force CloudFront to query both S3 buckets simultaneously for each request.
Cevap
Create a CloudFront origin group with the primary and backup S3 buckets, and configure the cache behavior to point to this origin group.
To set up automatic failover for static content distributed via CloudFront, you must create an origin group that contains a primary origin (the primary S3 bucket) and a secondary origin (the backup S3 bucket). You specify the failover criteria (e.g., HTTP 502 and 504 status codes) that trigger the failover. Finally, you configure the cache behavior to target the origin group so that requests are routed through this failover logic.
Adım Adım Çözüm
Anahtar Kavram
CloudFront Origin Groups and Origin Failover