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

Changes for TrieRange in FilteredTermEnum and MultiTermQuery improvement

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: 2.4, 2.9
    • Fix Version/s: 2.9
    • Component/s: None
    • Labels:
      None
    • Lucene Fields:
      New, Patch Available

      Description

      This is a patch, that is needed for the MultiTermQuery-rewrite of TrieRange (LUCENE-1602):

      • Make the private members protected, to have access to them from the very special TrieRangeTermEnum
      • Fix a small inconsistency (docFreq() now only returns a value, if a valid term is existing)
      • Improvement of MultiTermFilter.getDocIdSet to return DocIdSet.EMPTY_DOCIDSET, if the TermEnum is empty (less memory usage) and faster.
      • Add the getLastNumberOfTerms() to MultiTermQuery for statistics on different multi term queries and how may terms they affect, using this new functionality, the improvement of TrieRange can be shown (extract from test case there, 10000 docs index, long values):
        [junit] Average number of terms during random search on 'field8':
        [junit]  Trie query: 244.2
        [junit]  Classical query: 3136.94
        [junit] Average number of terms during random search on 'field4':
        [junit]  Trie query: 38.3
        [junit]  Classical query: 3018.68
        [junit] Average number of terms during random search on 'field2':
        [junit]  Trie query: 18.04
        [junit]  Classical query: 3539.42
        

      All core tests pass.

        Attachments

        1. LUCENE-1603.patch
          7 kB
          Uwe Schindler
        2. LUCENE-1603.patch
          7 kB
          Uwe Schindler
        3. LUCENE-1603.patch
          16 kB
          Uwe Schindler

          Issue Links

            Activity

              People

              • Assignee:
                mikemccand Michael McCandless
                Reporter:
                thetaphi Uwe Schindler
              • Votes:
                0 Vote for this issue
                Watchers:
                0 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: