A car rental company built a serverless REST API used by its mobile app. The stack uses Amazon API Gateway with a Regional endpoint, AWS Lambda, and an Amazon Aurora MySQL Serverless DB cluster. After opening access to partners, request volume rose sharply and caused intermittent database memory errors. Logs show many clients issue repeated HTTP GET requests for identical queries over short intervals. Traffic is concentrated during business hours with spikes on holidays. The company wants to support the increased load while minimizing cost growth. Which approach meets these requirements?
Choose an answer
Tap an option to check your answer.
Correct answer: Convert the API Gateway Regional endpoint to an edge-optimized endpoint. Enable caching in the production stage..
Why this is the answer
Converting to an edge-optimized API Gateway endpoint leverages Amazon CloudFront's global network, reducing latency for geographically dispersed users and absorbing some traffic before it reaches the regional API Gateway. Enabling caching directly within API Gateway for the production stage is crucial because the problem states many clients issue repeated HTTP GET requests for identical queries. Caching these responses at the API Gateway level prevents redundant calls to Lambda and Aurora, significantly reducing the load on the backend, minimizing database memory errors, and improving response times. This approach directly addresses the repeated query issue and scales efficiently without substantial cost increases. Implementing ElastiCache is a valid caching strategy but requires modifying Lambda functions, adding development overhead. Increasing Aurora memory only masks the symptom, not the root cause of repeated queries. Throttling requests would prevent legitimate traffic, negatively impacting user experience and partner access.
Pass your exam — without the endless answer hunt
Get every verified question and explanation for this exam in one place, and save hours of prep. 1,000+ certifications · 20+ languages · free to start.
Pass your exam faster → No card needed