IndicesRequestCache
uncancellably blocks search threads while result is pending
#108703
Labels
>bug
:Search/Search
Search-related issues that do not fall into other categories
Team:Search
Meta label for search team
A user reported to me that they had inadvertently run a very expensive collection of queries which caused stress to their cluster so they cancelled them, but some
indices:data/read/search[phase/query]
tasks continued to run for a very long time after being cancelled and eventually they had to restart nodes to restore their cluster back to a working state. They shared a thread dump which shows various places where we appear to be missing cancellation detection today, see #108701, but also in the thread dump I noticed that there were quite a fewsearch
threads blocking withinIndicesRequestCache.getOrCompute
apparently waiting for the result of the query that the other threads are computing.I think we should avoid filling up the
search
pool with these blocking tasks so that these threads can do other more meaningful work, but at the very least we should also make these cache interactions react to cancellations properly.The text was updated successfully, but these errors were encountered: