Details

    • Type: Task
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.0, 6.0
    • Component/s: core/store
    • Labels:
      None
    • Lucene Fields:
      New

      Description

      Spinoff of LUCENE-4746.

      This method is currently:

      copy(Directory to, String src, String dest, IOContext context)
      

      But it would be better to restructure this so the destination directory is the one actually being changed by the operation:

      copyFrom(Directory from, String src, String dest, IOContext context)
      

      Besides fixing the order to make sense, adding it to the name might help prevent bugs like the current TrackingDirectoryWrapper impl (used by IndexWriter to track what files are used):

      public void copy(Directory to, String src, String dest, IOContext context) throws IOException {
        createdFileNames.add(dest); // BUG!
        in.copy(to, src, dest, context);
      }
      

        Attachments

          Issue Links

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                rcmuir Robert Muir
              • Votes:
                1 Vote for this issue
                Watchers:
                3 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: