[ 
https://issues.apache.org/jira/browse/LUCENE-5911?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=14172338#comment-14172338
 ] 

Robert Muir commented on LUCENE-5911:
-------------------------------------

David: you are right.

This caching is unnecessary in my opinion.

Instead if the optional freeze() method is supposed to prepare internal 
structures for querying, I would have freeze() just prebuild, populate an 
ArrayList<NumericDocValues> (indexed by field number), by calling 
getNormValues() for each one. If you don't call freeze, this list is null, and 
it just returns a new one each time: not worth caching or anything for that 
case.

> 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
>            Assignee: Alan Woodward
>            Priority: Minor
>             Fix For: 5.0, Trunk
>
>         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: dev-unsubscr...@lucene.apache.org
For additional commands, e-mail: dev-h...@lucene.apache.org

Reply via email to