Skip to content

make sure all IndexSearcher instances use an executor #4008

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

Merged
merged 5 commits into from
Jul 26, 2022

Conversation

vladak
Copy link
Member

@vladak vladak commented Jul 25, 2022

For multi-segment indexes, it is desirable to use IndexSearcher with an executor so that the segments can be search in parallel.

This change addresses both indexer and webapp. For the former, the threads created should respect indexing parallelism level, for the latter the already existing search executor fixed thread pool should be used.

In a way this fixes the situation with ThreadpoolSearcherFactory - even though it is used to create IndexSearcher objects with a executor, these objects are not really used for searching (see #4009).

I verified with debugger/decompiler in IDEA that UI based searches that go through SearchHelper end up in the Lucene's search() method that actually submits tasks to the executor (based on leaves of the IndexReaderContext object associated with given IndexSearcher).

Complements PR #3983.

@vladak vladak added indexer webapp web application labels Jul 25, 2022
@oracle-contributor-agreement oracle-contributor-agreement bot added the OCA Verified All contributors have signed the Oracle Contributor Agreement. label Jul 25, 2022
@vladak vladak merged commit 4956def into oracle:master Jul 26, 2022
@vladak vladak deleted the index_searcher_executor branch July 26, 2022 07:26
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
indexer OCA Verified All contributors have signed the Oracle Contributor Agreement. webapp web application
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant