Details

    • Sub-task
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 5.3, 6.0
    • None
    • None
    • New

    Description

      FieldInfos.fieldInfo(int) looks up a field by number and returns its FieldInfo.
      This method is called per-field-per-doc in things like stored fields and vectors readers.

      Unfortunately, today this method is always backed by a TreeMap. In most cases a simple array is better, its faster and uses less memory.

      These changes made significant difference in stored fields checkindex time with my test index (had only 10 fields). Maybe it helps merge as well.

      Attachments

        1. LUCENE-6325.patch
          3 kB
          Robert Muir
        2. LUCENE-6325.patch
          3 kB
          Michael McCandless

        Activity

          People

            mikemccand Michael McCandless
            rcmuir Robert Muir
            Votes:
            0 Vote for this issue
            Watchers:
            3 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: