epotyom commented on code in PR #13568: URL: https://github.com/apache/lucene/pull/13568#discussion_r1678226435
########## lucene/facet/src/java/org/apache/lucene/facet/DrillSidewaysQuery.java: ########## @@ -195,11 +156,11 @@ public ScorerSupplier scorerSupplier(LeafReaderContext context) throws IOExcepti // a null scorer in this case, but we need to make sure #finish gets called on all facet // collectors since IndexSearcher won't handle this for us: if (baseScorerSupplier == null || nullCount > 1) { - if (drillDownCollector != null) { - drillDownCollector.finish(); + if (drillDownLeafCollector != null) { Review Comment: The problem is that `#finish` is a method of `LeafCollector`, not `Collector`. The way it used to work is that `FacetCollector` implements both `Collector` and `LeafCollector`, so `drillDownCollector.finish()` used to finish work for the current leaf. With this change we have to differentiate between the two interfaces, and call `#finish` on the leaf collector rather than Collector itself. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For queries about this service, please contact Infrastructure at: us...@infra.apache.org --------------------------------------------------------------------- To unsubscribe, e-mail: issues-unsubscr...@lucene.apache.org For additional commands, e-mail: issues-h...@lucene.apache.org