atris commented on a change in pull request #877: LUCENE-8978: Maximal Bottom 
Score Based Early Termination
URL: https://github.com/apache/lucene-solr/pull/877#discussion_r324221245
 
 

 ##########
 File path: 
lucene/core/src/java/org/apache/lucene/search/TopScoreDocCollector.java
 ##########
 @@ -138,14 +152,20 @@ public void collect(int doc) throws IOException {
           if (score > after.score || (score == after.score && doc <= 
afterDoc)) {
             // hit was collected on a previous page
             if (totalHitsRelation == TotalHits.Relation.EQUAL_TO && 
hitsThresholdChecker.isThresholdReached()) {
+              // Since the queue is prepopulated with sentinel objects, 
getting here means that the local
+              // priority queue is full
+              if (bottomValueChecker != null) {
 
 Review comment:
   Agreed -- The reason I did not put it in `updateMinCompetitiveScore` is 
because the function already became significantly heavy by the additions in 
this PR. Added now

----------------------------------------------------------------
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.
 
For queries about this service, please contact Infrastructure at:
[email protected]


With regards,
Apache Git Services

---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to