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

FSDirectory doesn't detect double-close nor usage after close

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: 1.9, 2.0.0, 2.1, 2.2, 2.3, 2.3.1
    • Fix Version/s: 2.4
    • Component/s: core/store
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      FSDirectory.close implements logic to ensure only a single instance of FSDirectory per canonical directory exists. This means code that synchronizes on the FSDirectory instance is also synchronized against that canonical directory. I think only IndexModifier (now deprecated) actually makes use of this, but I'm not certain.

      But, the close() method doesn't detect double close, and doesn't catch usage after being closed, and so one can easily get two instances of FSDirectory for the same canonical directory.

        Attachments

        1. LUCENE-1331.patch
          8 kB
          Michael McCandless

          Activity

            People

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

              Dates

              • Created:
                Updated:
                Resolved: