easyMultiple ChoiceObjective-mapped
Google ACE Practice Question: Deploy a new version of an App Engine standard…
You need to deploy a new version of an App Engine standard environment application. The new version should receive 10% of traffic while the current version continues to receive 90%. Which command achieves this?
⚠ Common exam trap
Google Cloud often tests the distinction between deploying a version (`deploy`), migrating all traffic (`migrate`), and splitting traffic (`set-traffic`), so the trap here is that candidates confuse `--no-promote` with traffic splitting, thinking it allocates a percentage of traffic when it actually just deploys without routing any traffic to the new version.
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
✓
`gcloud app services set-traffic default --splits v1=0.9,v2=0.1`
The `gcloud app services set-traffic` command explicitly splits traffic between versions of an App Engine service. By specifying `--splits v1=0.9,v2=0.1`, you direct 90% of requests to version v1 and 10% to version v2, without deploying a new version or promoting it. This is the standard method for gradual traffic migration in App Engine standard environment.
Answer analysis
Option-by-option breakdown
For each option: why learners choose it and why it is or isn't the right answer here.
- ✗
`gcloud app deploy --version=v2 --no-promote`
Why it's wrong here
While the `--no-promote` flag correctly avoids making v2 the default receiving version, this deploy command alone routes 0% of traffic to v2. It merely uploads the new version and leaves the current traffic split untouched, so v2 would be available but unreachable by live users. To achieve the 10% canary, you must follow this with a separate `set-traffic` call; thus, the command as given fails to satisfy the requirement.
- ✓
`gcloud app services set-traffic default --splits v1=0.9,v2=0.1`
Why this is correct
This is the exact command because it applies the required traffic split at the `default` service level without performing any new deployment. The `--splits` flag defines a percentage map: `v1=0.9` sends 90% of requests to v1, and `v2=0.1` sends the remaining 10% to v2. Both versions must already exist in the service, and this command is typically executed after deploying v2 with `--no-promote`. This achieves the canary pattern where the new version serves a small, controlled fraction of user traffic while the stable version handles the majority.
- ✗
`gcloud app versions migrate v2`
Why it's wrong here
This command is incorrect because `migrate` transitions all traffic from the current serving version(s) to v2 using a rolling strategy, ultimately leaving v2 at 100% of traffic. It cannot allocate a specific 10% share; it is designed for full promotion with zero downtime, not for a canary split. Running it would bypass the desired 90/10 distribution and route the entire user base to v2, which is far too aggressive for a controlled test.
- ✗
`gcloud app deploy --version=v2 --promote --stop-previous-version`
Why it's wrong here
This command is the opposite of a canary release: `--promote` immediately shifts 100% of the default service's traffic to v2, and `--stop-previous-version` goes further by shutting down v1 entirely. The combination completely replaces the stable version and removes the ability to roll back to v1 without a re-deployment. A 90/10 split requires keeping v1 active and serving most requests, not promoting v2 to full production and stopping v1.
Go deeper
Related to this question
Learn chapter
Google Compute Engine
Key term
App Engine
App Engine is a fully managed serverless platform from Google Cloud that lets developers build and deploy applications without worrying about the underlying infrastructure.
Key term
Service
A service is a software component or system that performs a specific function and is available to be used by other programs or users over a network.
About these practice questions
One of 769 original ACE practice questions on Courseiva, each with a full explanation and wrong-answer analysis — not exam dumps or protected exam content. Learn why practice questions differ from exam dumps →
JA
Written by Johnson Ajibi, MSc IT Security
Senior Network & Security Engineer · founder of Courseiva
This ACE practice question is part of Courseiva's free Google Cloud 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 ACE exam.