CoStudy

HomeCertificationsAWS Certified Developer DVA-C02 › Deployment

Deployment — AWS Certified Developer DVA-C02 practice questions

28 multiple-choice questions and 15 flashcards on Deployment, about 19% of the AWS Certified Developer DVA-C02 bank. Every one carries a written rationale.

Written and maintained by Nick Burton · last updated 2026-08-22 · how we write and review questions

What this chapter covers

Deployment is one of 4 chapters in CoStudy's AWS Certified Developer — Associate (DVA-C02) bank, and it holds 28 of the bank's 150 multiple-choice questions — roughly 19% of the total. That proportion is not arbitrary: chapters follow the certifying body's published exam outline, and the number of questions in each is set by that domain's published weight, so the share of your practice time this chapter takes matches the share of the real exam it accounts for.

Studying by chapter is worth doing once you have a diagnostic score. A single overall percentage tells you whether you are close; it does not tell you which domain is dragging. Working a weak chapter in isolation, and re-testing it in isolation, is the fastest way to move a score that has stalled — and it is why the mock exams in CoStudy report by domain rather than as one number.

Free Deployment practice questions

7 questions drawn from this chapter, with the full rationale shown — the controlling principle behind the right answer, and why each wrong option tempts and fails.

Which CloudFormation reference points to a value EXPORTED from another stack?

  1. ImportValue for cross-stack export
  2. GetAtt for same-stack attribute
  3. Ref for same-stack resource
  4. FindInMap looks up mapping

Answer: A — ImportValue for cross-stack export

C) Ref returns a resource's default value in the same stack. B) GetAtt fetches an attribute in the same stack. A) Correct — ImportValue reads a cross-stack Output export. D) FindInMap looks up a mapping table.

Which SAM CLI command creates a live dev loop that hot-updates cloud resources on save?

  1. sam sync --watch hot-updates
  2. sam build --watch compiles local
  3. sam init only scaffolds project
  4. sam deploy --guided one-shot

Answer: A — sam sync --watch hot-updates

C) sam init only scaffolds. B) sam build compiles locally without deploy. A) Correct — sam sync --watch continuously updates code and infra in the deployed stack. D) sam deploy is one-shot.

Which CodeBuild construct defines phases, artifacts, and env vars for a build?

  1. buildspec.yml drives CodeBuild
  2. appspec.yml is CodeDeploy artifact
  3. template.yaml is SAM/CFN template
  4. samconfig.toml stores CLI defaults

Answer: A — buildspec.yml drives CodeBuild

B) appspec is a CodeDeploy artifact. A) Correct — buildspec.yml governs CodeBuild install, pre_build, build, and post_build phases. C) template.yaml is SAM/CFN. D) samconfig.toml stores sam CLI defaults.

In a blue/green deployment, how is production traffic moved from old to new environment?

  1. Rolling upgrade in place on the same fleet
  2. Weighted routing shift from blue to green
  3. Ad-hoc SSH into each instance to patch
  4. Manual DNS TTL expiration for each host

Answer: B — Weighted routing shift from blue to green

A) Rolling upgrades reuse the same instances and lose easy rollback. B) Correct — traffic is shifted via ALB target-group weights or Route 53 records, keeping blue for rollback. C) Manual patching defeats automation. D) TTL waiting is uncontrolled.

Which CloudFormation attribute retains a resource when the stack is DELETED?

  1. UpdateReplacePolicy: Retain
  2. DependsOn: Retain for ordering
  3. DeletionPolicy: Retain the resource
  4. Metadata: Retain informational

Answer: C — DeletionPolicy: Retain the resource

A) UpdateReplacePolicy governs replacements during updates, not deletion. C) Correct — DeletionPolicy: Retain preserves the resource after stack delete. B) DependsOn only orders creation. D) Metadata is informational.

A CodeDeploy Lambda deployment with Canary10Percent5Minutes preset does what?

  1. Shifts 5% traffic for 10 min then 100%
  2. Shifts 10% traffic for 5 min then 100%
  3. Deploys all at once with 5-min delay
  4. Shifts 10% each minute over 10 min

Answer: B — Shifts 10% traffic for 5 min then 100%

B) Correct — 10% goes to the new version for 5 minutes; if alarms stay clean, 100% shifts next. A) Reverses the percentages. C) Would be All-at-once with delay. D) That describes a linear preset.

Which CodePipeline stage does CodeBuild typically execute in?

  1. Source stage pulls from repo
  2. Build stage runs the buildspec
  3. Deploy stage pushes artifacts
  4. Approve stage is manual gate

Answer: B — Build stage runs the buildspec

A) Source pulls artifacts from Git or S3. B) Correct — CodeBuild compiles, tests, and packages within the Build stage. C) Deploy pushes artifacts. D) Approve is a manual gate.

Deployment flashcards

4 cards from the 15 in this chapter.

AWS SAM?

Serverless Application Model. Extension of CloudFormation for serverless apps.

CloudFormation?

Infrastructure as code. Define resources in YAML/JSON templates. Deploys as stack.

Elastic Beanstalk?

PaaS for apps. Handles infrastructure (EC2, ELB, autoscale). Just upload code.

CloudFormation nested stacks?

Stack within a stack. Reusable templates.

Practise the full chapter

These are a sample. The full Deployment chapter runs 43 items with per-chapter progress tracking, on the web and in the iOS app.

Open AWS Certified Developer DVA-C02 in CoStudy →

Other AWS Certified Developer DVA-C02 chapters

All AWS Certified Developer DVA-C02 practice questions →