Q52 — AWS DOP-C02 Ch.1

Question 52 of 100 | ← Chapter 1

A DevOps engineer manages a web application running on Amazon EC2 instances behind an Application Load Balancer (ALB). These instances run in an EC2 Auto Scaling group spanning multiple Availability Zones. The engineer needs to implement the following deployment strategy: 1. Launch a second fleet of instances with identical capacity to the original fleet. 2. Keep the original fleet running while deploying to the second fleet. 3. Shift traffic to the second fleet once it is fully deployed. 4. Automatically terminate the original fleet one hour after the traffic shift.

Correct Answer: C. Use AWS CodeDeploy with a deployment group configured for blue/green deployment. Select the option to terminate the original instances in the deployment group, with a wait time of one hour.

Explanation

The described strategy is a classic blue/green deployment requiring traffic shifting and delayed termination of the original fleet. AWS CodeDeploy natively supports blue/green deployments with configurable termination policies—including waiting for a specified duration (e.g., one hour) after successful traffic routing before terminating the original instances. This precisely matches requirements 1–4. Option B is incorrect because Elastic Beanstalk blue/green deployments do not support configurable post-traffic-shift termination delays; lifecycle policies govern application version retention, not fleet termination timing. Options A and D misapply CloudFormation and Elastic Beanstalk features unrelated to orchestrated fleet termination. Therefore, Option C is the correct and supported solution.