AWS Certified Developer – Associate — Question 352
A developer runs an application that uses an Amazon API Gateway REST API. The developer needs to implement a solution to proactively monitor the health of both API responses and latencies in case a deployment causes a service disruption despite passing deployment pipeline tests. The solution also must check for endpoint vulnerability and unauthorized changes to APIs, URLs, and website content.
Which solution will meet these requirements?
Answer options
- A. Use the Amazon CloudWatch Synthetics canary functionality to call the API and check the responses and duration of the request.
- B. Use a custom health check in the API that queries hosts to check the duration of the request.
- C. Implement a custom AWS Lambda function with an Amazon EventBridge event to periodically call the API and check the responses and duration of the request.
- D. Use the built-in API Gateway metrics to monitor the average duration of the API response.
Correct answer: A
Explanation
Amazon CloudWatch Synthetics canaries allow developers to continuously monitor endpoints and APIs by simulating customer behavior, making it ideal for checking latencies, response validity, endpoint vulnerabilities, and unauthorized content drift. While a custom AWS Lambda function with Amazon EventBridge (Option C) could perform basic API calls, it requires custom development to match CloudWatch Synthetics' native capabilities. Native API Gateway metrics (Option D) and basic host health checks (Option B) do not provide the comprehensive external validation and content vulnerability verification needed.