Q86 — AWS DOP-C02 Ch.2

Question 86 of 100 | ← Chapter 2

A DevOps engineer is building a CI/CD pipeline for a serverless application that uses AWS Lambda functions. The company wants to minimize the impact of failed deployments on customers and also wants monitoring capabilities. Which deployment strategy configuration meets these requirements?

Correct Answer: A. Use an AWS Serverless Application Model (AWS SAM) template to define the serverless application. Deploy the Lambda function using AWS CodeDeploy with a Canary10Percent15Minutes deployment preference type. Use Amazon CloudWatch alarms to monitor the function's health.

Explanation

The AWS Serverless Application Model (SAM) enables declarative definition of Lambda functions and related resources via templates, simplifying deployment. AWS CodeDeploy's Canary deployment type (e.g., 10% traffic for 15 minutes) gradually shifts traffic, minimizing blast radius of failures. Amazon CloudWatch alarms provide real-time health monitoring to detect issues early. Option B introduces manual approval delays and lacks progressive traffic shifting. Option C does not explicitly implement staged traffic shifting and thus fails to control risk effectively. Option D lacks automated phased deployment and relies on reactive rollback rather than proactive prevention. AWS documentation recommends using CodeDeploy's Canary or Linear deployment strategies combined with CloudWatch alarms for safe, reliable Lambda deployments.