Uploaded image for project: 'Lucene - Core'
  1. Lucene - Core
  2. LUCENE-8060

Enable top-docs collection optimizations by default

Details

    • Improvement
    • Status: Reopened
    • Minor
    • Resolution: Fixed
    • None
    • 8.0
    • None
    • None
    • New

    Description

      We are getting optimizations when hit counts are not required (sorted indexes, MAXSCORE, short-circuiting of phrase queries) but our users won't benefit from them unless we disable exact hit counts by default or we require them to tell us whether hit counts are required.

      I think making hit counts approximate by default is going to be a bit trappy, so I'm rather leaning towards requiring users to tell us explicitly whether they need total hit counts. I can think of two ways to do that: either by passing a boolean to the IndexSearcher constructor or by adding a boolean to all methods that produce TopDocs instances. I like the latter better but I'm open to discussion or other ideas?

      Attachments

        1. LUCENE-8060.patch
          12 kB
          Adrien Grand
        There are no Sub-Tasks for this issue.

        Activity

          People

            Unassigned Unassigned
            jpountz Adrien Grand
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: