Lucene - Core
  1. Lucene - Core
  2. LUCENE-1718

IndexReader.setTermInfosIndexDivisor doesn't carry over to reopened readers

    Details

    • Type: Bug Bug
    • Status: Closed
    • Priority: Major Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 2.9
    • Component/s: core/index
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      When you reopen a reader, some segments are shared (and thus properly inherit the index divisor) but others are newly opened and use the default index divisor. You then have no way to change the index divisor of those newly opened ones. The only workaround is to not use reopen (always open a new reader).

      I'd like to make termInfosDivisor an up-front param to IndexReader, anyway, for LUCENE-1609, so likely I'll fix both of these issues there.

        Activity

        Hide
        Tim Smith added a comment -

        perfect

        i had checked your last patch on LUCENE-1609 and hadn't seen any explicit handling of this situation yet, so just wanted to call it out

        Show
        Tim Smith added a comment - perfect i had checked your last patch on LUCENE-1609 and hadn't seen any explicit handling of this situation yet, so just wanted to call it out
        Hide
        Michael McCandless added a comment -

        Thanks Tim. This should be fixed with LUCENE-1609: DirectoryReader now holds onto the termInfosIndexDivisor and passes it when opening new SegmentReaders during reopen.

        Show
        Michael McCandless added a comment - Thanks Tim. This should be fixed with LUCENE-1609 : DirectoryReader now holds onto the termInfosIndexDivisor and passes it when opening new SegmentReaders during reopen.
        Hide
        Michael McCandless added a comment -

        Fixed with LUCENE-1609.

        Show
        Michael McCandless added a comment - Fixed with LUCENE-1609 .

          People

          • Assignee:
            Michael McCandless
            Reporter:
            Michael McCandless
          • Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved:

              Development