# Search getting 429 Too Many Requests

**URL:** https://forum.opensearch.org/t/search-getting-429-too-many-requests/18598
**Category:** OpenSearch
**Tags:** discuss, troubleshoot
**Created:** [March 27, 2024, 5:12pm UTC](https://forum.opensearch.org/t/search-getting-429-too-many-requests/18598 "2024-03-27T17:12:43Z")
**Posts on this page:** 4
**Page:** 1

<div class="post-metadata">

### Author: ![CarolynR](https://avatars.discourse-cdn.com/v4/letter/c/71e660/32.png) [@CarolynR](https://forum.opensearch.org/u/CarolynR)
#### Post date: [March 27, 2024, 5:12pm UTC](https://forum.opensearch.org/t/search-getting-429-too-many-requests/18598/1 "2024-03-27T17:12:43Z")

</div>

**Versions** (relevant - OpenSearch/Dashboard/Server OS/Browser):  
Opensearch 2.11.1  
Custom Dashboards  
OS redhat 9.3, but running inside a docker container

**Describe the issue** :  
Initially when my dashboard is displayed, all the visualizations are fine. If I click on the ‘Refresh’ button after only a few seconds, some of the visualizations will show an error of 429 ‘Too Many Requests’.  
If I wait another minute and click on Refresh, all the visualizations will once again be OK.

It appears that Opensearch isn’t waiting for all the threads to complete.

**Configuration** :  
These same dashboards worked fine under Opensearch 2.8  
With upgrading to Opensearch 2.11.1, we have implemented security that uses roles and tenants.

**Relevant Logs or Screenshots** :

 ![image](https://us1.discourse-cdn.com/flex019/uploads/mauve_hedgehog/original/2X/d/dc31e1761cc7601b0c66975462515e43a1aa70f7.jpeg)

![image](https://us1.discourse-cdn.com/flex019/uploads/mauve_hedgehog/original/2X/0/0b46b8167a52bbe3133a35c616bd1fb91b7ea109.jpeg)

 ![image](https://us1.discourse-cdn.com/flex019/uploads/mauve_hedgehog/original/2X/3/379252d6e4d15c8f64c21b609f57b76988d118da.png)

When all the visualizations are working correctly, I see numbers in active and queue.

 ![image](https://us1.discourse-cdn.com/flex019/uploads/mauve_hedgehog/original/2X/9/91c81f5c65315f8bd59d6aaad8e1e1382e9c4686.png)

When I start seeing the 429, I do not see numbers in active and queue.

 ![image](https://us1.discourse-cdn.com/flex019/uploads/mauve_hedgehog/original/2X/0/07794c14416e31d35693f541ae54d9990afc7744.png)

---

<div class="post-metadata">

### Author: ![Gsmitt](https://sea1.discourse-cdn.com/flex019/user_avatar/forum.opensearch.org/gsmitt/32/1718_2.png) [@Gsmitt](https://forum.opensearch.org/u/Gsmitt)
#### Post date: [March 29, 2024, 12:57am UTC](https://forum.opensearch.org/t/search-getting-429-too-many-requests/18598/2 "2024-03-29T00:57:04Z")

</div>

Hey @CarolynR

> [@CarolynR](#):
>
> error of 429 ‘Too Many Requests’

This might be from memory usage to exceed the maximum size of the Java heap.  
Have you tried increasing you heap?

---

<div class="post-metadata">

### Author: ![CarolynR](https://avatars.discourse-cdn.com/v4/letter/c/71e660/32.png) [@CarolynR](https://forum.opensearch.org/u/CarolynR)
#### Post date: [March 29, 2024, 12:05pm UTC](https://forum.opensearch.org/t/search-getting-429-too-many-requests/18598/3 "2024-03-29T12:05:32Z")

</div>

Yes, I increased the java heap to 4x its original size and the behavior didn’t change. I am wondering what kind of clean up it does such that after a few minutes I can successfully refresh the dashboard.

Is there any other information I can provide that will help someone diagnose this problem?

Does the application of roles and tenants use many more resources?

---

<div class="post-metadata">

### Author: ![CarolynR](https://avatars.discourse-cdn.com/v4/letter/c/71e660/32.png) [@CarolynR](https://forum.opensearch.org/u/CarolynR)
#### Post date: [April 4, 2024, 8:55pm UTC](https://forum.opensearch.org/t/search-getting-429-too-many-requests/18598/4 "2024-04-04T20:55:33Z")

</div>

Just case someone else runs into something like this, it is caused by rate limiting in the application we use for additional security. We needed to increase the default values.
