Q57 — AWS DOP-C02 Ch.3
Question 57 of 100 | ← Chapter 3
A DevOps engineer wants to monitor the health of a stateless RESTful service behind a Classic Load Balancer. New application revisions are deployed via a CI/CD pipeline. If service latency exceeds a defined threshold, deployment must halt until the service recovers. Which method enables the fastest detection and response?
- A. Use Amazon CloudWatch metrics provided by Elastic Load Balancing to calculate average latency. Trigger an alarm and stop deployment when latency exceeds the defined threshold. ✓
- B. Use AWS Lambda and Elastic Load Balancing access logs to detect average latency. Trigger an alarm and stop deployment when latency exceeds the defined threshold.
- C. Use AWS CodeDeploy’s MinimumHealthyHosts setting to define rollback thresholds. Roll back the deployment if these thresholds are violated.
- D. Use metric filters to parse application logs in Amazon CloudWatch Logs. Create a latency filter. Trigger an alarm and stop deployment when latency exceeds the defined threshold.
Correct Answer: A. Use Amazon CloudWatch metrics provided by Elastic Load Balancing to calculate average latency. Trigger an alarm and stop deployment when latency exceeds the defined threshold.
Explanation
Option A is optimal because: (1) Real-time capability: Amazon CloudWatch metrics provide near real-time monitoring with high update frequency, enabling rapid latency change detection. (2) Simplicity: CloudWatch metrics and alarms require minimal configuration compared to log parsing or custom Lambda logic. (3) Integration: CloudWatch integrates natively with CI/CD pipelines, allowing immediate alarm-triggered deployment halts. Options B, C, and D involve higher latency (log processing delays), greater complexity, or misaligned scope (C addresses host health, not latency). Thus, A delivers the fastest detection and response.