[
https://issues.apache.org/jira/browse/LUCENE-5911?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
]
Alan Woodward updated LUCENE-5911:
----------------------------------
Attachment: LUCENE-5911.patch
In the end I decided that the nicest API change was to add a freeze() method
which prepares the internal data structures for querying, and prevents users
adding new fields. You can continue to use MemoryIndex as in the past, but if
you want to search in multiple threads, call freeze() first.
Also adds a new test, and renames the existing test to be a bit more
descriptive of what it's actually doing.
> Make MemoryIndex thread-safe for queries
> ----------------------------------------
>
> Key: LUCENE-5911
> URL: https://issues.apache.org/jira/browse/LUCENE-5911
> Project: Lucene - Core
> Issue Type: Improvement
> Reporter: Alan Woodward
> Priority: Minor
> Attachments: LUCENE-5911.patch, LUCENE-5911.patch
>
>
> We want to be able to run multiple queries at once over a MemoryIndex in
> luwak (see
> https://github.com/flaxsearch/luwak/commit/49a8fba5764020c2f0e4dc29d80d93abb0231191),
> but this isn't possible with the current implementation. However, looking
> at the code, it seems that it would be relatively simple to make MemoryIndex
> thread-safe for reads/queries.
--
This message was sent by Atlassian JIRA
(v6.3.4#6332)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]