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

IndexWriter retains references to Readers used in Fields (memory leak)

    Details

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

      Description

      As described in [1] IndexWriter retains references to Reader used in Fields and that can lead to big memory leaks when using tika's ParsingReaders (as those can take 1MB per ParsingReader).

      [2] shows a screenshot of the reference chain to the Reader from the IndexWriter taken with Eclipse MAT (Memory Analysis Tool) . The chain is the following:

      IndexWriter -> DocumentsWriter -> DocumentsWriterThreadState -> DocFieldProcessorPerThread -> DocFieldProcessorPerField -> Fieldable -> Field (fieldsData)

      -------------
      [1] http://markmail.org/thread/ndmcgffg2mnwjo47
      [2] http://skitch.com/ecerulm/n7643/eclipse-memory-analyzer

        Attachments

        1. LUCENE-2387.patch
          0.6 kB
          Michael McCandless
        2. ASF.LICENSE.NOT.GRANTED--LUCENE-2387-29x.patch
          1 kB
          Michael McCandless

          Activity

            People

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

              Dates

              • Created:
                Updated:
                Resolved: