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

NRTCachingDir has invalid asserts (if same file name is written twice)

Details

    • Bug
    • Status: Closed
    • Major
    • Resolution: Fixed
    • None
    • 3.6, 4.0-ALPHA
    • None
    • None
    • New

    Description

      Normally Lucene is write-once (except for segments.gen file, which NRTCachingDir never caches), but in some tests (TestDoc, TestCrash) we can write the same file more than once.

      I don't think NRTCachingDir should have these asserts, and I think on createOutput it should remove any old file if present.

      I also found & fixed a possible concurrency issue (if more than one thread syncs at the same time; IndexWriter doesn't ever do this today but it has in the past).

      Attachments

        1. LUCENE-3658.patch
          11 kB
          Michael McCandless

        Activity

          People

            mikemccand Michael McCandless
            mikemccand Michael McCandless
            Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: