Uploaded image for project: 'Hadoop Common'
  1. Hadoop Common
  2. HADOOP-8176

Disambiguate the destination of FsShell copies

    XMLWordPrintableJSON

Details

    • Bug
    • Status: Resolved
    • Major
    • Resolution: Fixed
    • 0.23.2, 0.24.0
    • 0.23.2
    • fs
    • None

    Description

      The copy commands currently do not provide a way to disambiguate the expected destination of a copy. Ex.
      fs -put myfile path/mydir

      If "mydir" is an existing directory, then the copy produces path/mydir/file. If "mydir" does not exist at all, the copy produces path/mydir. The file has unexpectedly been renamed to what was expected to be a directory! It's standard unix shell behavior, but it lacks a special trait.

      Unix allows a user to disambiguate their intent by allowing path/mydir/ or path/mydir/. to mean "mydir" is always be treated as a directory. If the copy succeeds, it will always be called path/mydir/myfile.

      Attachments

        1. HADOOP-8176.patch
          4 kB
          Daryn Sharp

        Activity

          People

            daryn Daryn Sharp
            daryn Daryn Sharp
            Votes:
            0 Vote for this issue
            Watchers:
            5 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: