Question

Difficulty: MediumDeployment Strategy Design

An enterprise is planning to roll out a major update to its global web application. The application's static assets are hosted in an Amazon S3 bucket and served through an Amazon CloudFront distribution. The update requires changes to the CloudFront configuration, including new origin request policies and updated cache behaviors. The security and operations teams require that these changes be tested with a small percentage of live production traffic before being fully deployed, with the ability to roll back immediately if anomalies are detected.

Which combination of steps should a Solutions Architect recommend to meet these requirements with the least operational overhead? (Select TWO.)

  1. Create a staging CloudFront distribution that is linked to the primary distribution, and apply the new configuration changes to the staging distribution.Answer
  2. Create a CloudFront continuous deployment policy that specifies a weight-based traffic split to route a percentage of requests to the staging distribution, and associate it with the primary distribution.Answer
  3. C
    Create a second independent CloudFront distribution with the same alternate domain name (CNAME), and configure Amazon Route 53 weighted routing policies to split DNS traffic between the two distributions.
  4. D
    Deploy a Lambda@Edge function associated with the Viewer Request event of the primary distribution to dynamically modify the origin request headers and route traffic to a staging S3 bucket.
  5. E
    Configure AWS CodeDeploy with a custom canary deployment configuration to manage the lifecycle and traffic routing for the primary CloudFront distribution.

Answer

Create a staging CloudFront distribution linked to the primary distribution, apply the configuration changes to the staging distribution, and then create and associate a continuous deployment policy that specifies a weight-based traffic split to route a percentage of requests to the staging distribution.
Using CloudFront continuous deployment is the recommended AWS best practice for testing CDN configuration changes with live traffic. Creating a staging distribution linked to the primary distribution provides a safe sandbox for configurations like origin request policies and cache behaviors. Associating a weight-based continuous deployment policy ensures a percentage of production traffic is routed to the staging distribution without DNS caching issues or custom code overhead, enabling immediate rollbacks if anomalies are detected.

Step-by-Step Solution

1
Set up the test environment using CloudFront's native features.
A staging distribution linked to the primary distribution is created, hosting the new configuration (origin request policies and cache behaviors) in isolation.
This allows applying modifications safely without affecting production traffic.
2
Configure and attach the routing policy.
A weight-based continuous deployment policy is created and associated with the primary distribution, directing a specific percentage of requests to the staging distribution.
This enables testing the new distribution configuration with a subset of live traffic under production conditions.
3
Monitor performance and prepare for promotion or rollback.
If issues arise, the continuous deployment policy can be deleted or disabled to instantly route all traffic back to the primary configuration. If successful, the staging distribution can be promoted to production.
This guarantees zero downtime and zero DNS propagation delay during rollbacks.

Key Concept

CloudFront Continuous Deployment
Estimated Time:3m 0s
Rate this question