restprimo.blogg.se

Request was throttled
Request was throttled










Request was throttled code#

Use CloudWatch Logs to identify and eliminate errors, and have your function code handle exceptions. Increased invocations can lead to an increase in concurrency.

request was throttled

Increased errors can lead to retries and cause an overall increase in invocations. When the function is in an Amazon VPC, see How do I give internet access to a Lambda function that's connected to an Amazon VPC?Ĭheck for an increase in Errors metrics for your function You can add the function to an Amazon Virtual Private Cloud (Amazon VPC). Note: Changing the memory setting can affect the charges that you incur for execution time. Then, use AWS X-Ray and CloudWatch Logs to isolate the cause of duration increases. Try increasing the function's memory setting. If your function code is taking too long to complete, there might not be enough compute resources. Note: To work around burst concurrency limits, you can configure provisioned concurrency.Ĭheck for spikes in Duration metrics for your functionĬoncurrency depends on function duration. If you're limited by burst scaling, then you see a spike of Throttles that corresponds to a stair-step pattern of ConcurrentExecutions on the graph.

request was throttled

On the Metrics page for Lambda in the CloudWatch console, reduce the graph's time range to 1 minute. See if the maximum ConcurrentExecutions are close to your account-level concurrency quota in the Region, along with corresponding data points in the Throttles graph.Ĭheck if you're exceeding the initial burst concurrency quota for a particular AWS Region View the Maximum statistic for ConcurrentExecutions and the Sum statistic for Throttles. Review your Lambda metrics in Amazon CloudWatchĬheck the ConcurrentExecutions metric for your function in the AWS Region where you see throttling.Ĭompare the ConcurrentExecutions metric with the Throttles metric for the same timestamp Check your function's concurrency metrics Note: If you need a higher transactions per second (TPS) quota for an API call, then request a service quota increase. If certain API calls are throttled, make sure that you use exponential backoff in your code to retry the API calls. If there are no Lambda Throttles metrics, then the throttling is happening on API calls in your Lambda function code.Ĭheck your function code for any throttled API calls

request was throttled

To confirm what resource is throttled, check the following resources.Ĭheck your Amazon CloudWatch Logs to see if there are throttling errors, but no corresponding data points in the Lambda Throttles metrics Throttles can also occur on API calls during your function's invocation. Throttle errors might not be from your Lambda function. To troubleshoot Lambda throttling issues, including Rate exceeded and TooManyRequestsException errors, review the following steps. Even though Lambda automatically scales to accommodate incoming traffic, your function can still be throttled for various reasons. Lambda functions are sometimes throttled to protect your resources and downstream applications.










Request was throttled