AWS Certified DevOps Engineer – Professional (DOP-C02) — Question 355
A company is developing an ecommerce application on AWS. The company wants to make sure that the application can handle sudden increases in traffic.
The company uses AWS CodePipeline for its CI/CD process. The company must implement a solution to integrate automated load testing into the CI/CD pipeline to validate the application's performance. The solution must perform production deployment only if the performance exceeds a threshold.
Which solution will meet these requirements with the LEAST operational overhead?
Answer options
- A. Deploy the application by using AWS Elastic Beanstalk. Enable load balancing. Use Elastic Beanstalk to deploy tools for load tests. Run the tests during each deployment, and roll back the deployment if performance thresholds are unmet. Create an AWS Lambda function to monitor test metrics. Set up alarms for performance thresholds. Configure Amazon EventBridge to return an error if a test fails and to proceed with production deployment if a test passes.
- B. Implement AWS Fargate tasks to run tools for load tests. Use Amazon Elastic container Service (Amazon ECS) to manage the test containers. Create AWS Lambda functions to analyze the test results. Integrate the functions with CodePipeline by using custom actions to initiate and evaluate the tests. Program the functions to return an error if a test fails and to proceed with production deployment if a test passes.
- C. Launch Amazon EC2 instances to run tools for load tests. Store test scripts in a GitHub repository. Use AWS Step Functions to orchestrate the tests and result analysis in the CodePipeline workflow. Use Amazon EventBridge to invoke an AWS Lambda function based on the test results. Program the function to return an error if a test fails and to proceed with production deployment if a test passes.
- D. Use AWS CodeBuild to run tools for load tests, store the test artifacts in Amazon S3, and configure a CodePipeline stage to invoke the CodeBuild project. Use Amazon CloudWatch to monitor the test metrics and to set up alarms for performance thresholds. Integrate an AWS Lambda function into the pipeline by using a custom action. Program the function to return an error if a test fails and to proceed with production deployment if a test passes.
Correct answer: D
Explanation
Using AWS CodeBuild to run load tests and Amazon S3 to store artifacts minimizes operational overhead because CodeBuild is a fully managed, serverless build service that integrates natively with AWS CodePipeline. Integrating an AWS Lambda function as a custom action to evaluate CloudWatch metrics and alarms allows the pipeline to dynamically halt or proceed with production deployment based on performance thresholds. Other options, such as managing EC2 instances or ECS/Fargate container infrastructure specifically for load testing, introduce significantly more administrative and operational overhead.