AWS Certified Solutions Architect – Professional (SAP-C02) — Question 365

A car rental company has built a serverless REST API to provide data to its mobile app. The app consists of an Amazon API Gateway API with a Regional endpoint, AWS Lambda functions, and an Amazon Aurora MySQL Serverless DB cluster. The company recently opened the API to mobile apps of partners. A significant increase in the number of requests resulted, causing sporadic database memory errors.

Analysis of the API traffic indicates that clients are making multiple HTTP GET requests for the same queries in a short period of time. Traffic is concentrated during business hours, with spikes around holidays and other events.

The company needs to improve its ability to support the additional usage while minimizing the increase in costs associated with the solution.

Which strategy meets these requirements?

Answer options

Correct answer: A

Explanation

Enabling caching on the API Gateway production stage offloads redundant HTTP GET requests before they ever reach the Lambda functions or the Aurora database, significantly reducing database memory load and costs. Converting to an edge-optimized endpoint further improves latency for external partners by utilizing CloudFront edge locations. Other solutions, such as adding ElastiCache or scaling Aurora, are more expensive and complex, while throttling would negatively impact integration partner experience by dropping requests.