LUCENE-7238: Explicitly disable the query cache in MemoryIndex.createSearcher.

This commit is contained in:
Adrien Grand 2016-04-21 17:01:43 +02:00
parent 81446cf345
commit 2ee8426d5e
2 changed files with 4 additions and 0 deletions

View File

@ -73,6 +73,9 @@ Optimizations
* LUCENE-7235: LRUQueryCache should not take a lock for segments that it will
not cache on anyway. (Adrien Grand)
* LUCENE-7238: Explicitly disable the query cache in MemoryIndex#createSearcher.
(Adrien Grand)
Bug Fixes
* LUCENE-7127: Fix corner case bugs in GeoPointDistanceQuery. (Robert Muir)

View File

@ -666,6 +666,7 @@ public class MemoryIndex {
MemoryIndexReader reader = new MemoryIndexReader();
IndexSearcher searcher = new IndexSearcher(reader); // ensures no auto-close !!
searcher.setSimilarity(normSimilarity);
searcher.setQueryCache(null);
return searcher;
}