AWS API throttling rate exceeded error giving you trouble?
At Bobcares, as a part of our AWS Support Service, we have a solution for every query you may have.
Let’s take a look at how our Support Techs helped out a client with the Rate exceeded error recently.
What is AWS API throttling rate exceeded error?
Did you know that cannot exceed the maximum allowed number of allowed API request rates per account as well as per AWS Region? In fact, this is regardless of whether the calls came from an application, the AWS CLI, or the AWS Management Console.
In case we exceed the rate, we will wind up with a “Rate Exceeded” error and throttled API calls.
Furthermore, it is also possible to receive errors due to API calls made directly to Elastic Beanstalk or other AWS services like AWS Cloudformation.
How to solve AWS API throttling rate exceeded error?
- Check with API calls are throttled
- Check “describe” calls in the Elastic Beanstalk environment
- Verify calls from third-party applications
- Via error retries and exponential backoffs
- Request for service limit increase
Check with API calls are throttled
- First, we will identify the throttling error and note the timeframe of the error in the Elastic Beanstalk event stream.
- Then, we will use AWS CloudTrail to examine events with the RequestLimitExceeded errors. We will also validate the eventSource. EventName and the userAgent.
Check “describe” calls in the Elastic Beanstalk environment
Interestingly, too many “describe” calls can cause an increase in API requests. In other words, we can validate the describe calls in the Elastic Beanstalk environment using either of the following approaches:
- With EnvironmentResourceDescription as seen below:
$ aws ec2 describe-instances --filters Name="tag:elasticbeanstalk:environment-id",Values="Your_Environment_ID"
- With DescribeInstances API call via filters for the Elastic Beanstalk tags. For instance:
$ aws ec2 describe-instances --filters Name="tag:elasticbeanstalk:environment-name",Values="Your_Environment_Name"
Verify calls from third-party applications
Third-party applications can also make continuous calls to any AWS service managed by Elastic Beanstalk.
Our Support Engineers recommend checking whether your third=party applications are making unnecessary calls with the help of CloudTrail. All we need to do is check the user agent that is making the calls.
Via error retries and exponential backoffs
We can also use exponential backoffs and error retries to limit the number of API calls. Additionally, each AWS SDK also implements an automatic retry logic as well as exponential backoff algorithms.
Request for service limit increase
Before we can request for a service limit increase in the AWS Service center, we have to do the following:
- First, identify the API call as well as the call rate.
- Then, try using exponential backoffs or error retries.
- Include the AWS Region, the use-case for a limit increase, and timeframe specific to throttling issues while requesting service limit increase.
[Looking for assistance with AWS? Give us a call today.]
At the end of the day, we learned all about resolving API throttling and Rate exceeded errors from the skilled Support Engineers at Bobcares.