AWS Certified Solutions Architect – Professional — Question 221
A company is having issues with a newly deployed serverless infrastructure that uses Amazon API Gateway, Amazon Lambda, and Amazon DynamoDB.
In a steady state, the application performs as expected. However, during peak load, tens of thousands of simultaneous invocations are needed and user requests fail multiple times before succeeding. The company has checked the logs for each component, focusing specifically on Amazon CloudWatch Logs for Lambda.
There are no errors logged by the services or applications.
What might cause this problem?
Answer options
- A. Lambda has very low memory assigned, which causes the function to fail at peak load.
- B. Lambda is in a subnet that uses a NAT gateway to reach out of the internet, and the function instance does not have sufficient Amazon EC2 resources in the VPC to scale with the load.
- C. The throttle limit set on API Gateway is very low. During peak load, the additional requests are not making their way through to Lambda.
- D. DynamoDB is set up in an auto scaling mode. During peak load, DynamoDB adjusts capacity and throughput behind the scenes, which is causing the temporary downtime. Once the scaling completes, the retries go through successfully.
Correct answer: C
Explanation
The correct answer is C because if the throttle limit on API Gateway is too low, it can prevent additional requests from reaching the Lambda function during peak times, thus causing failures. Option A is incorrect as memory allocation issues would likely lead to logged errors. Option B is not the cause since it refers to resource limitations within a VPC rather than API Gateway throttling. Option D is misleading because while DynamoDB can auto scale, it is unlikely to cause request failures if properly configured.