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

SegmentInfos shouldn't blindly increment version on commit

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

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 3.1, 4.0-ALPHA
    • Component/s: core/index
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      SegmentInfos currently increments version on the assumption that there are always changes.

      But, both DirReader and IW are more careful about tracking whether there are changes. DirReader has hasChanges and IW has changeCount. I think these classes should notify the SIS when there are in fact changes; this will fix the case Simon hit on fixing LUCENE-2082 when the NRT reader thought there were changes, but in fact there weren't because IW simply committed the exact SIS it already had.

        Attachments

        1. LUCENE-2805.patch
          3 kB
          Michael McCandless
        2. LUCENE-2805.patch
          6 kB
          Simon Willnauer
        3. LUCENE-2805.patch
          11 kB
          Simon Willnauer
        4. LUCENE-2805_3x.patch
          12 kB
          Simon Willnauer

        Issue Links

          Activity

            People

            • Assignee:
              simonw Simon Willnauer
              Reporter:
              mikemccand Michael McCandless

              Dates

              • Created:
                Updated:
                Resolved:

                Issue deployment