question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

[BUG] 429 too many requests - heap issue

See original GitHub issue

Describe the bug The issue is extremely similar to #1583, the symptoms are the same, i.e. after an amount of time, we get 429 response code, too many requests. However, the return data includes:

image

(apologies for the low res…) You can see: data too large, data for... which is larger than the limit of ....

That tipped us off since it ties the issue to JVM heap memory. In fact, on restart the issue is cleared. Looking at our monitoring, the JVM heap memory shows a clear leak:

image

The y-axis shows % heap used. The massive dip was on restart of opensearch. Both before and after the restart there’s a subtle but clear leak.

To Reproduce Difficult to reproduce. We’re not doing anything special in terms of setup. The setup is:

  • baremetal opensearch
  • single server
  • indexing done via bulk API index calls
  • high write activity, low read activity (we index way more than we query)
  • more details will be posted in a comment below

Expected behavior No heap memory leak

Plugins All default plugins except “security” and “ilm”, more details in comment below

Host/Environment (please complete the following information):

  • OS: Centos7
  • Version opensearch 1.2.3

Additional context There doesnt seem to be a high queue or thread count when the problem starts. We modified the JVM XMX and XMS arguments from 30Gb to 37GB, with not much difference

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:7

github_iconTop GitHub Comments

1reaction
dvas0004commented, Jun 27, 2022

@amitmun the server displaying these symptoms is in production so it’s difficult to reproduce properly. What we have noticed is that “closing” older indices using the close api seems to keep this under control…

1reaction
amitmuncommented, Jun 26, 2022

We see exactly the same behavoir with OpenSearch 1.2.4 on RHEL and currently working on creating an environment to recreate this in order to try and resolve it. Everything works for a while until GC starts to go wild and almost all requests fail (including simple requests like getting a single doc by ID). Restarting is the only workaround we currently have. @dvas0004 - have you found out the root cause for this issue yet? If we successfully recreate I can share heap dumps and heap histo and test solutions like upgrading OpenSearch etc.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to Fix 429 Too Many Requests Error Code - Hostinger
Don't know how to deal with the 429 too many requests error? We'll share the six effective solutions to diagnose and resolve it!...
Read more >
How to fix WordPress 429 Too Many Requests Error? - Cloudzy
HTTP-status-code “error 429 too many requests” indicates that too many data requests have been sent by the user in a relatively short time...
Read more >
429 Error: How to Fix & Avoid It in the Future - Naturaily
An error mainly associated with WordPress plugins – too many requests – tells the client application to stop sending requests because they don't ......
Read more >
How To Fix '429 Too Many Requests' error In WordPress
The 429 Too Many Requests error occurs when WordPress tries to send too many requests to the server. This error system is in...
Read more >
node.js - Elasticsearch 429 Too Many Requests _bulk with ...
A 429 error message as a write rejection indicates a bulk queue error. The es_rejected_execution_exception[bulk] indicates that your queue ...
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found