LUCENE-8062: GlobalOrdinalsQuery is no longer eligible for caching

This commit is contained in:
Jim Ferenczi 2017-11-28 14:56:28 +01:00
parent 207e546122
commit a06e685642
2 changed files with 6 additions and 1 deletions

View File

@ -121,6 +121,8 @@ Optimizations
* LUCENE-7994: Use int/int scatter map to gather facet counts when the
number of hits is small relative to the number of unique facet labels
(Dawid Weiss, Robert Muir, Mike McCandless)
* LUCENE-8062: GlobalOrdinalsQuery is no longer eligible for caching. (Jim Ferenczi)
Tests

View File

@ -156,7 +156,10 @@ final class GlobalOrdinalsQuery extends Query {
@Override
public boolean isCacheable(LeafReaderContext ctx) {
return DocValues.isCacheable(ctx, joinField);
// disable caching because this query relies on a top reader context
// and holds a bitset of matching ordinals that cannot be accounted in
// the memory used by the cache
return false;
}
}