-
Notifications
You must be signed in to change notification settings - Fork 25.2k
Revise Default max concurrent search requests #31192
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
Comments
Pinging @elastic/es-search-aggs |
In #31171 I originally used the avg. number of shards per index in the high level request which had issues as @jpountz stated:
I think what we want to achieve here is that we gain a certain level of concurrency while at the same time don't overload the cluster with a search request hitting a large number of shards on a small number of nodes. The smallish clusters with large shard counts are the critical ones here IMO if a query matching all shards causing rejections because the queue of the search threadpool on a single node fills up quickly. So with a queue size or 1000 on the search threadpool I do think we have quite some room here to have a simple default like I also looked into the CCS issue which is not an issue after all since we take the number of nodes that participate in the request into account already. In-fact the CCS way is actually better because it only takes into account the nodes that participate in the request. I wonder if we should change the way we use this number and limit the number of concurrent shards requests per node instead. We can then do this dynamically in |
I think this metric makes more sense and is easier to reason about. +1 |
+1 to making this a per-target node limit instead of a global one. |
+1 |
With `max_concurrent_shard_requests` we used to throttle / limit the number of concurrent shard requests a high level search request can execute per node. This had several problems since it limited the number on a global level based on the number of nodes. This change now throttles the number of concurrent requests per node while still allowing concurrency across multiple nodes. Closes elastic#31192
With `max_concurrent_shard_requests` we used to throttle / limit the number of concurrent shard requests a high level search request can execute per node. This had several problems since it limited the number on a global level based on the number of nodes. This change now throttles the number of concurrent requests per node while still allowing concurrency across multiple nodes. Closes #31192
Spinoff from #31171
We today use
5 * numNodes
in the cluster as the default number of concurrent search requests issues by a single high level request. This has several issues ie. in the CCS case. There is also valid arguments that this number is arbitrary. Lets discuss this and find a good default that also works for CCSThe text was updated successfully, but these errors were encountered: