Courseiva
Continuous Improvement for Existing SolutionshardMultiple ChoiceObjective-mapped

SAP-C02 Continuous Improvement for Existing Solutions Practice Question

A company runs a critical web application on EC2 instances behind an Application Load Balancer (ALB). During a recent deployment, users experienced errors. The team wants to automatically roll back the deployment if the error rate exceeds 5% within 10 minutes after deployment. Which solution meets these requirements with minimal operational overhead?

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

Use CodeDeploy with a CloudWatch alarm on the ALB error rate that triggers a deployment rollback.

AWS CodeDeploy supports automatic rollback based on CloudWatch alarm metrics, such as the ALB error rate exceeding 5% for 10 minutes, with minimal operational overhead. Option A is incorrect because modifying Auto Scaling group health checks does not directly monitor application-level error rates for rollback. Option B is incorrect because manual approval gates require human intervention and do not provide automatic rollback. Option D is incorrect because using a custom Lambda function adds complexity and is not the best practice; CodeDeploy with CloudWatch alarms provides a simpler, fully managed solution.

Answer analysis

Option-by-option breakdown

For each option: why learners choose it and why it is or isn't the right answer here.

  • Configure the Auto Scaling group to use ELB health checks and replace instances if the error rate increases.

    Why it's wrong here

    Auto Scaling health checks do not monitor error rate percentages for rollback.

  • Use CodeDeploy with manual approval gates and a script that checks error rates.

    Why it's wrong here

    Manual approval does not provide automatic rollback based on error rate.

  • Use CodeDeploy with a CloudWatch alarm on the ALB error rate that triggers a deployment rollback.

    Why this is correct

    CodeDeploy natively supports CloudWatch alarm-based automatic rollback.

  • Use a custom Lambda function that monitors ALB error rates and triggers a rollback via CodeDeploy API.

    Why it's wrong here

    Developing custom Lambda logic introduces significant operational overhead because it requires manual integration between CloudWatch metrics and CodeDeploy APIs. This approach is intended for bespoke monitoring requirements that standard deployment hooks cannot handle, such as checking external third-party API health. However, AWS CodeDeploy natively supports CloudWatch Alarm triggers to automate rollbacks during deployments, satisfying the requirement for minimal management without writing custom code.

Quick reference

Cloud Service Model Comparison

ModelYou ManageProvider ManagesExamples
IaaSOS, runtime, apps, dataHardware, hypervisor, networkingEC2, Azure VMs, GCP Compute Engine
PaaSApps and dataOS, runtime, middleware, hardwareElastic Beanstalk, Azure App Service
SaaSData and settings onlyEverything elseMicrosoft 365, Salesforce, Workday
FaaS / ServerlessFunction code onlyInfra, scaling, runtimeLambda, Azure Functions, Cloud Run
CaaSContainers and appsKubernetes, OS, hardwareEKS, AKS, GKE

About these practice questions

This SAP-C02 question is part of Courseiva's 1,660-question bank — original exam-style content with full explanations and wrong-answer analysis, never real exam questions or exam dumps. Learn why practice questions differ from exam dumps →

How Courseiva writes practice questions · Editorial policy

JA

Written by Johnson Ajibi, MSc IT Security

Senior Network & Security Engineer · founder of Courseiva

This SAP-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 SAP-C02 exam.