A mission-critical, autoscaling application must be updated one instance at a time so the rest of the fleet stays serving traffic. The instance being updated is CPU-intensive and must be monitored; if its CPU exceeds 85% the deployment should automatically roll back. Which solution satisfies these requirements?
Choose an answer
Tap an option to check your answer.
Correct answer: Use AWS CodeDeploy with Amazon EC2 Auto Scaling. Create an alarm on the instance CPU utilization. Use the CodeDeployDefault.OneAtATime deployment configuration. Configure automatic rollbacks for the deployment group to rollback if the CPU alarm is breached..
Why this is the answer
The correct solution leverages AWS CodeDeploy's native integration with Amazon EC2 Auto Scaling for controlled deployments and automatic rollbacks. The CodeDeployDefault.OneAtATime deployment configuration ensures updates are applied to one instance at a time, maintaining application availability. Configuring an Amazon CloudWatch alarm for CPU utilization and linking it to CodeDeploy's automatic rollback feature directly addresses the requirement for rolling back if CPU exceeds 85%. The other options are less suitable: AWS Step Functions and Systems Manager Automation can orchestrate complex deployments but are overkill and more complex for this specific scenario compared to CodeDeploy's built-in features. Elastic Beanstalk's rolling deployments can achieve one-at-a-time updates, but CodeDeploy offers more granular control over rollback conditions tied directly to deployment health. Systems Manager for blue/green deployments is a valid strategy but the question specifically asks for one-instance-at-a-time updates within the existing fleet, which is a rolling update pattern, not typically blue/green. Also, Systems Manager itself doesn't directly handle the "automatic rollback when alarm breached" for deployments in the same integrated way CodeDeploy does.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed