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

Add FSLockFactory.toString()

    XMLWordPrintableJSON

    Details

    • Type: Improvement
    • Status: Closed
    • Priority: Minor
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 4.7, 6.0
    • Component/s: core/store
    • Labels:
      None
    • Lucene Fields:
      New, Patch Available

      Description

      FSLockFactory doesn't override toString, which causes Dir.toString() to print the class.name@instance. I think it would be better if it printed e.g. the lockDir.

      I added it but TestCrashCausesCorruptIndex failed because it declares a Directory which doesn't override getLockID(), which returns toString(). I changed that Directory to extend FilterDirectory, and fixed FilterDirectory to override getLockID() to call in.getLockID().

      Will attach a patch shortly.

        Attachments

        1. LUCENE-5431.patch
          4 kB
          Shai Erera
        2. LUCENE-5431.patch
          7 kB
          Shai Erera

          Activity

            People

            • Assignee:
              shaie Shai Erera
              Reporter:
              shaie Shai Erera
            • Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

              Dates

              • Created:
                Updated:
                Resolved: