mirror of https://github.com/apache/lucene.git
LUCENE-7787: HeatmapFacetCounter Bits.MatchNoBits optimization
This commit is contained in:
parent
d5e5b5e948
commit
7d57d63375
|
@ -102,6 +102,11 @@ Improvements
|
|||
* LUCENE-7782: OfflineSorter now passes the total number of items it
|
||||
will write to getWriter (Mike McCandless)
|
||||
|
||||
Optimizations
|
||||
|
||||
* LUCENE-7787: spatial-extras HeatmapFacetCounter will now short-circuit it's
|
||||
work when Bits.MatchNoBits is passed. (David Smiley)
|
||||
|
||||
Other
|
||||
|
||||
* LUCENE-7754: Inner classes should be static whenever possible.
|
||||
|
|
|
@ -142,6 +142,9 @@ public class HeatmapFacetCounter {
|
|||
}
|
||||
|
||||
final Heatmap heatmap = new Heatmap(columns, rows, ctx.makeRectangle(heatMinX, heatMaxX, heatMinY, heatMaxY));
|
||||
if (topAcceptDocs instanceof Bits.MatchNoBits) {
|
||||
return heatmap; // short-circuit
|
||||
}
|
||||
|
||||
//All ancestor cell counts (of facetLevel) will be captured during facet visiting and applied later. If the data is
|
||||
// just points then there won't be any ancestors.
|
||||
|
|
Loading…
Reference in New Issue