Skip to content

Don't use ThrottledTaskRunner for async cache evictions #129458

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Draft
wants to merge 2 commits into
base: main
Choose a base branch
from

Conversation

nicktindall
Copy link
Contributor

@nicktindall nicktindall commented Jun 16, 2025

Minor improvement to asynchronous shared blob cache evictions

  • Avoids creating the additional lambda
  • Only allows a single executor thread

In testing the deletion of 2,000 searchable snapshots, the time taken for the cluster state update was

  • The pre-optimization version took ~1.9s
  • The optimised version took ~900ms
  • This version took ~600ms

The pre-optimised version would increase exponentially with the amount deleted, whereas the difference between the status quo and this change would be linear. It also looks like the JIT kicked in by the time the third node did the evictions and then all implementations went down to ~200 -> 220ms. So I guess the. danger is the first time this happens on a node that hasn't JIT-ted the cache eviction codepath?

Not sure if it's worth the additional complexity.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants