Soru

Zorluk: OrtaDeployment Strategy Design

A solutions architect is designing the deployment strategy for a critical transaction processing microservice running on Amazon ECS with the AWS Fargate launch type behind an Application Load Balancer (ALB). The business requires a deployment strategy that minimizes the blast radius of new releases by routing exactly 10%10\% of client traffic to the new version initially. The remaining 90%90\% of traffic must be routed to the new version after a 10-minute observation period, provided no errors are detected. If the microservice experiences an elevated 5XX error rate during the transition, the system must execute an automated rollback to the previous version within 2 minutes. Which deployment strategy and configuration should the solutions architect select to satisfy these requirements?

  1. Configure an AWS CodeDeploy blue/green deployment for the Amazon ECS service using the CodeDeployDefault.ECSCanary10Percent10Minutes deployment configuration, and associate CloudWatch alarms on the ALB target group's 5XX error rate directly with the CodeDeploy deployment group.Cevap
  2. B
    Configure an AWS CodeDeploy blue/green deployment for the Amazon ECS service using the CodeDeployDefault.ECSLinear10PercentEvery10Minutes deployment configuration, and configure an AWS Lambda function triggered by a CloudWatch Event rule to delete the new task set if the ALB 5XX error rate alarm is triggered.
  3. C
    Configure an Amazon ECS rolling update by setting the MinimumHealthyPercent to 100 and MaximumPercent to 200, and use AWS CloudFormation rollback triggers based on CloudWatch alarms monitoring the ALB target group's 5XX error rate.
  4. D
    Deploy the new version as a separate Amazon ECS service, use AWS Route 53 weighted routing policies to distribute traffic between the two ECS service load balancers with a 10/90 ratio, and configure Route 53 DNS failover based on health checks to roll back traffic.

Cevap

Configure an AWS CodeDeploy blue/green deployment for the Amazon ECS service using the CodeDeployDefault.ECSCanary10Percent10Minutes deployment configuration, and associate CloudWatch alarms on the ALB target group's 5XX error rate directly with the CodeDeploy deployment group.
The correct answer is to use AWS CodeDeploy with a blue/green deployment type and select the ECSCanary10Percent10Minutes configuration. This configuration shifts 10%10\% of the traffic to the new task set, waits for 10 minutes, and then shifts the remaining 90%90\% if no alarms are triggered. Linking CloudWatch alarms on the 5XX error rate directly to the CodeDeploy deployment group ensures that CodeDeploy automatically and immediately rolls back traffic to the previous version if the alarm is breached, easily meeting the 2-minute rollback requirement.

Adım Adım Çözüm

1
Analyze the traffic shifting requirements.
The requirement is to shift 10%10\% of traffic initially, wait for 10 minutes, and then shift the remaining 90%90\%. This matches a Canary deployment pattern, specifically CodeDeploy's Canary10Percent10Minutes configuration.
Linear configurations shift traffic incrementally over multiple intervals, whereas canary configurations shift a specific portion once and then shift the rest after a soak period.
2
Evaluate the rollback mechanism against the 2-minute constraint.
Native AWS CodeDeploy blue/green deployments support linking CloudWatch alarms to the deployment group. When an alarm is triggered, CodeDeploy immediately stops the deployment and routes all traffic back to the original task set.
This native integration operates within seconds of the alarm state change, meeting the 2-minute automated rollback requirement. Using Route 53 DNS failover or custom Lambda code introduces propagation delays and complexity.

Anahtar Kavram

AWS CodeDeploy blue/green deployments with canary configurations and native CloudWatch alarm integrations allow for precise traffic shifting and near-instant automated rollbacks.
Bu soruyu puanla