Uploaded image for project: 'Solr'
  1. Solr
  2. SOLR-14554

BMW algorithm isn't used when scores are requested

Attach filesAttach ScreenshotVotersWatch issueWatchersCreate sub-taskLinkCloneUpdate Comment AuthorReplace String in CommentUpdate Comment VisibilityDelete Comments
    XMLWordPrintableJSON

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • 8.6, 9.0
    • 8.6, 9.0
    • None
    • None

    Description

      This is because, when scores are requested, we use MultiCollector, and it will end up using a scorer that explicitly skips delegating calls to set the minimum competitive score:

      @Override
          public void setScorer(Scorable scorer) throws IOException {
            if (cacheScores) {
              scorer = new ScoreCachingWrappingScorer(scorer);
            }
            scorer = new FilterScorable(scorer) {
              @Override
              public void setMinCompetitiveScore(float minScore) throws IOException {
                // Ignore calls to setMinCompetitiveScore so that if we wrap two
                // collectors and one of them wants to skip low-scoring hits, then
                // the other collector still sees all hits. We could try to reconcile
                // min scores and take the maximum min score across collectors, but
                // this is very unlikely to be helpful in practice.
              }
      
            };
            for (int i = 0; i < numCollectors; ++i) {
              final LeafCollector c = collectors[i];
              c.setScorer(scorer);
            }
          }
      

      Attachments

        Issue Links

        Activity

          This comment will be Viewable by All Users Viewable by All Users
          Cancel

          People

            tflobbe Tomas Eduardo Fernandez Lobbe
            tflobbe Tomas Eduardo Fernandez Lobbe
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved:

              Time Tracking

                Estimated:
                Original Estimate - Not Specified
                Not Specified
                Remaining:
                Remaining Estimate - 0h
                0h
                Logged:
                Time Spent - 20m
                20m

                Slack

                  Issue deployment