DVA-C02 Deployment Practice Question
A developer is deploying a containerized application to Amazon ECS with the Fargate launch type using AWS CodeDeploy for blue/green deployments. The application is behind an Application Load Balancer (ALB). What is the minimum number of ALB target groups required for a blue/green deployment?
⚠ Common exam trap
A common mix-up: candidates assume a single target group is sufficient because they think of the ALB as handling traffic routing on its own, but they miss that blue/green deployments require two separate target groups to isolate the old and new environments for traffic shifting and rollback.
Answer choices
Why each option matters
Answer the question above first, then reveal the full breakdown to understand why each option is right or wrong.
Correct answer & explanation
✓
2
In a blue/green deployment with Amazon ECS (Fargate) and AWS CodeDeploy, the deployment process requires two distinct target groups: one for the 'blue' (current) environment and one for the 'green' (new) environment. CodeDeploy shifts traffic from the blue target group to the green target group during the deployment, allowing for instant rollback by switching back. A single target group cannot differentiate between the two environments, and three or more are unnecessary because the blue/green model only needs two active target groups at any time.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
1
Why it's wrong here
A single target group is insufficient for an automated blue/green deployment strategy because it cannot simultaneously point to both the old ("blue") and new ("green") versions of the application. To perform a traffic shift, the target group would need to be reconfigured to point to the new tasks, which would either cause downtime during the update or require manual intervention to validate the new version before the swap, thereby defeating the purpose of an automated, seamless blue/green process.
- ✓
2
Why this is correct
Two target groups are precisely what AWS CodeDeploy requires for a blue/green deployment with Amazon ECS. One target group is associated with the currently active "blue" task set, receiving all production traffic. The second target group is then associated with the newly deployed "green" task set, allowing for validation before CodeDeploy automatically shifts traffic from the "blue" target group to the "green" target group via Application Load Balancer listener rule updates, ensuring a controlled, zero-downtime transition.
- ✗
3
Why it's wrong here
Three target groups are not necessary for implementing a standard blue/green deployment on Amazon ECS with CodeDeploy. While technically possible to configure, adding a third target group introduces unnecessary complexity and management overhead without providing any additional functional benefit for the core blue/green traffic shifting mechanism. The fundamental requirement is to have distinct environments for the old and new versions, which two target groups efficiently fulfill.
- ✗
4
Why it's wrong here
Four target groups are significantly over-engineered and entirely superfluous for a basic blue/green deployment strategy on Amazon ECS. This configuration would introduce substantial complexity in setup, management, and cost without enhancing the core capability of isolating and shifting traffic between two application versions. The robust and proven pattern for blue/green deployments relies on exactly two target groups to manage the active and new task sets effectively.
Go deeper
Related to this question
About these practice questions
Courseiva writes every DVA-C02 question from scratch — 724 in total, each with an explanation and a wrong-answer breakdown. None are copied from real exams or dumps. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This DVA-C02 practice question is part of Courseiva's free Amazon Web Services certification practice question bank. Courseiva provides original exam-style practice questions with explanations, topic-based practice, mock exams, readiness tracking, and study analytics to help learners prepare for the DVA-C02 exam.