use current node load estimation when placing search jobs#6390
Open
trinity-1686a wants to merge 8 commits intomainfrom
Open
use current node load estimation when placing search jobs#6390trinity-1686a wants to merge 8 commits intomainfrom
trinity-1686a wants to merge 8 commits intomainfrom
Conversation
PSeitz
reviewed
May 7, 2026
| fn compute_split_cost(split_metadata: &SplitMetadata) -> usize { | ||
| pub(crate) fn compute_split_cost(num_docs: u64) -> usize { | ||
| // TODO this formula could be tuned a lot more. The general idea is that there is a fixed | ||
| // cost to searching a split, plus a somewhat-linear cost depending on the size of the split |
Collaborator
There was a problem hiding this comment.
this should include if we have aggregations or not, or ideally a cost from the query
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
When placing jobs, first query all nodes for their current load, and bias placement toward less loaded nodes to even load on the cluster
this improves on a problem where some nodes might be overloaded while other are underloaded, causing queueing despite not all nodes being at max capacity
in testing, this was seen improving slightly p50+ under constant light load, and increased the max qps before latency explodes. Metrics also showed all searcher busy when some would be only part-time working before
future improvements: