Question

Difficulty: MediumDeployment Strategy Design

A company is designing the deployment strategy for a microservice running on Amazon ECS with the AWS Fargate launch type. The microservice requires a baseline of 10 tasks to meet performance requirements. The deployment process must adhere to the following constraints:

* The service must experience zero downtime.
* The compute cost during the deployment must not exceed 130% of the normal baseline cost.
* If a new version fails container health checks, the deployment must automatically roll back to the previous version without manual intervention.

Which two configurations should the Solutions Architect specify in the ECS service definition and deployment pipeline to meet these requirements? (Select TWO.)

  1. Configure the service to use the ECS rolling update (ECS) deployment controller, and enable the deployment circuit breaker with rollback.Answer
  2. Set the deployment configuration parameters minimumHealthyPercent to 100 and maximumPercent to 130.Answer
  3. C
    Configure the service to use the AWS CodeDeploy (CODE_DEPLOY) deployment controller, and specify the ECSLinear10PercentEvery1Minute deployment configuration.
  4. D
    Set the deployment configuration parameters minimumHealthyPercent to 70 and maximumPercent to 100.
  5. E
    Configure the service to use the ECS rolling update (ECS) deployment controller, and set minimumHealthyPercent to 100 and maximumPercent to 200.

Answer

Configure the service to use the ECS rolling update deployment controller with the deployment circuit breaker and rollback enabled, and set the deployment configuration parameters to a minimum healthy percent of 100 and a maximum percent of 130.
To achieve zero downtime without exceeding a 30% temporary increase in compute cost, the ECS service must perform a rolling update (using the ECS deployment controller) where the minimum healthy percentage is set to 100% (ensuring all 10 baseline tasks remain running) and the maximum percentage is set to 130% (limiting the maximum tasks to 13). Additionally, enabling the ECS deployment circuit breaker with the rollback feature ensures that if the new tasks fail health checks, the service automatically rolls back to the previous stable state.

Step-by-Step Solution

1
Analyze the capacity and cost constraints during the deployment.
The baseline is 10 tasks. Zero downtime means the number of running healthy tasks must not drop below 10 (minimum healthy percent must be at least 100%). The cost must not exceed 130% of the baseline, which means the maximum running tasks during deployment must not exceed 13 (maximum percent must be at most 130%).
To determine the bounds for the ECS deployment configuration parameters.
2
Evaluate the deployment controllers against the capacity constraints.
AWS CodeDeploy blue/green deployments (using the CODE_DEPLOY controller) instantiate a full replacement task set (100% additional capacity, or 20 tasks total) before starting traffic shifting. This violates the 130% cost limit. Thus, the native ECS rolling update controller must be used.
To eliminate the CodeDeploy deployment controller option.
3
Determine the automatic rollback mechanism for the ECS rolling update controller.
The Amazon ECS deployment circuit breaker can be enabled with rollback. If the new task set fails health checks, ECS will automatically roll back to the previously successful version.
To satisfy the requirement for automatic, non-manual rollbacks.

Key Concept

ECS Rolling Updates and Deployment Circuit Breaker Capacity Management
Rate this question