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

Merging should pass correct fieldinfos to producers always

Details

    • Bug
    • Status: Open
    • Major
    • Resolution: Unresolved
    • None
    • None
    • None
    • None
    • New

    Description

      I think its been a longstanding issue, but I noticed it in the bulk merge code today and see that we can fix it...

      instead of:

      DocumentStoredFieldVisitor visitor = new DocumentStoredFieldVisitor();
      storedFieldsReader.visitDocument(docID, visitor);
      Document doc = visitor.getDocument();
      addDocument(doc, mergeState.mergeFieldInfos);
      

      we should do:

      addDocument(doc, mergeState.fieldInfos[i]);
      

      This is a lot more consistent and reduce the possibility of scary bugs during merge because the codec does something strange. We should look into all merge logic to see if it can be improved here.

      Attachments

        Activity

          People

            Unassigned Unassigned
            rcmuir Robert Muir
            Votes:
            0 Vote for this issue
            Watchers:
            1 Start watching this issue

            Dates

              Created:
              Updated: