BrainyBeeBrainyBee
ExploreBlogStart Studying
HomeAWS Certified Developer - Associate (DVA-C02)Mastering AWS CI/CD: Continuous Integration and Continuous Delivery for Developers
Study Guide945 words

Mastering AWS CI/CD: Continuous Integration and Continuous Delivery for Developers

Deploy code by using AWS Continuous Integration and Continuous Delivery (CI/CD) services

Mastering AWS CI/CD: Continuous Integration and Continuous Delivery for Developers

This study guide covers the core AWS DevOps tools and practices essential for the AWS Certified Developer - Associate (DVA-C02) exam, focusing on Domain 3: Deployment.

Learning Objectives

By the end of this guide, you should be able to:

  • Identify the core AWS CI/CD services: CodeCommit, CodeBuild, CodeDeploy, and CodePipeline.
  • Describe different Lambda deployment packaging options (Zip vs. Container Image).
  • Configure and differentiate between deployment strategies like Blue/Green, Canary, and Rolling.
  • Update Infrastructure as Code (IaC) templates (SAM/CloudFormation) for automated pipelines.
  • Manage application environments and perform rollbacks in case of failure.

Key Terms & Glossary

  • Continuous Integration (CI): The practice of frequently merging code changes into a central repository, followed by automated builds and tests.
  • Continuous Delivery (CD): An extension of CI where code changes are automatically prepared for a release to production.
  • Continuous Deployment: A step beyond delivery where every change that passes the pipeline is automatically deployed to production without manual intervention.
  • Artifact: A file or set of files (e.g., a .zip, .jar, or Docker image) produced by the build process that is ready for deployment.
  • Webhook: A mechanism that triggers a pipeline or action when an event occurs in a source repository (e.g., a git push).

The "Big Idea"

The "Big Idea" behind CI/CD is to shorten the feedback loop. By automating the path from a developer's machine to the production environment, teams can release features faster, reduce human error in deployments, and ensure that software is always in a releasable state. It transforms deployment from a high-risk event into a routine, automated process.

Formula / Concept Box

Deployment Strategies Comparison

StrategyDescriptionBest ForRisk Level
All-at-OnceUpdates all instances simultaneously. Downtime occurs.Dev/Test environmentsHigh
RollingUpdates instances in batches. No downtime, but two versions exist at once.General web appsMedium
CanaryDeploys to a small % of users first, then scales if successful.Testing new featuresLow
Blue/GreenProvisions a new environment (Green) and swaps traffic from the old (Blue).Fast rollbacks, Zero downtimeLow

Hierarchical Outline

  1. AWS CI/CD Service Stack
    • AWS CodeCommit: Managed Git-based version control. Secure and highly scalable.
    • AWS CodeBuild: Managed build service that compiles code, runs tests, and produces artifacts. Uses a buildspec.yml file.
    • AWS CodeDeploy: Automates code deployment to EC2, Lambda, ECS, and On-premises.
    • AWS CodePipeline: The orchestrator that links source, build, and deploy stages together.
  2. Deployment Management
    • Lambda Packaging: Can be packaged as .zip files (max 50MB direct / 250MB unzipped) or Container Images (up to 10GB).
    • API Gateway Stages: Uses stage variables to point to different Lambda aliases (e.g., PROD vs DEV).
  3. Infrastructure as Code (IaC)
    • AWS SAM: An extension of CloudFormation for serverless applications.
    • CloudFormation: Uses JSON/YAML templates to define and provision infrastructure.

Visual Anchors

The CI/CD Pipeline Workflow

Loading Diagram...

Blue/Green Deployment Traffic Shift

Compiling TikZ diagram…
⏳
Running TeX engine…
This may take a few seconds

Definition-Example Pairs

  • In-Place Deployment: A deployment where the existing instances are stopped and the new version is installed.
    • Example: Updating a single EC2 instance by stopping the web server, replacing the code, and restarting it.
  • Manual Approval: A step in a pipeline where a human must review and click "Approve" before the process continues.
    • Example: A manager reviewing the results of a Staging build before allowing CodePipeline to deploy to Production.
  • Linear Deployment (Lambda): A traffic-shifting strategy where traffic grows by a fixed percentage every X minutes.
    • Example: Shifting 10% of traffic to a new Lambda version every 1 minute until 100% is reached.

Worked Examples

Example 1: Updating a SAM Template for a New Environment

To deploy a serverless app to a new environment (e.g., testing), you must update the Parameters section of your AWS SAM template.

  1. Open template.yaml.
  2. Define a parameter for the environment name:
    yaml
    Parameters: EnvName: Type: String Default: dev
  3. Use the parameter in resource names or environment variables using !Ref EnvName.
  4. Deploy using the CLI: sam deploy --parameter-overrides EnvName=testing.

Example 2: Configuring a Canary Release for Lambda

Using CodeDeploy and Lambda Aliases:

  1. Create a Lambda function version and an alias called live.
  2. In the AppSpec.yml file, specify the Type: AWS::Lambda::Function.
  3. Set DeploymentPreference to Canary10Percent5Minutes.
  4. CodeDeploy will shift 10% of traffic to the new version, wait 5 minutes, and then shift the remaining 90% if no CloudWatch Alarms are triggered.

Checkpoint Questions

  1. Which file is required by AWS CodeBuild to define build commands and artifact locations?
  2. What is the main difference between a "Rolling" deployment and a "Blue/Green" deployment regarding resource count?
  3. True or False: AWS CodePipeline can use GitHub or Bitbucket as a source provider.
  4. How does API Gateway handle different versions of an API without changing the URL?

[!TIP] Always ensure your CodeBuild service-role has the necessary permissions to upload artifacts to S3, or your pipeline will fail at the Build stage.

▶Click to see answers
  1. buildspec.yml
  2. Rolling uses existing resources (no extra cost/capacity initially), while Blue/Green provisions a full set of new resources (temporarily doubling capacity/cost).
  3. True.
  4. By using Stages (e.g., /prod, /dev) and stage variables.
All AWS Certified Developer - Associate (DVA-C02) Study Resources

Related Notes

  • Lab: Automating Application Delivery with AWS CI/CD Pipelines945 words
  • AWS X-Ray: Mastering Annotations and Metadata for Service Tracing864 words
  • Mastering Application Performance Analysis: AWS DVA-C02 Study Guide945 words
  • Optimizing Application Resource Requirements1,050 words
  • Mastering Root Cause Analysis: AWS Developer Associate Study Guide985 words
  • Root Cause Analysis Mastery: Debugging Serverless Applications on AWS920 words
  • Mastering IAM Role Assumption & AWS STS865 words
  • Automating Deployment Testing in AWS865 words
  • Lab: Automating Deployment Testing with AWS CI/CD and SAM920 words
  • AWS CloudFront: Caching Content Based on Request Headers1,150 words
  • Study Guide: Committing Code to Invoke Automated CI/CD Pipelines895 words
  • Mastering Application Health Checks and Readiness Probes985 words

Ready to study AWS Certified Developer - Associate (DVA-C02)?

Practice tests, flashcards, and all study notes — free, no sign-up.

Start Studying

Ready to study AWS Certified Developer - Associate (DVA-C02)?

Practice tests, flashcards, and all study notes — free, no sign-up needed.

Start Studying — Free
AWS Certified Developer - Associate (DVA-C02) ResourcesExplore All HivesBlogHome

© 2026 BrainyBee. Free AI-powered exam prep.