Uploaded image for project: 'Hadoop Distributed Data Store'
  1. Hadoop Distributed Data Store
  2. HDDS-766

Ozone shell create volume fails if volume name does not have a leading slash

    XMLWordPrintableJSON

    Details

    • Type: Bug
    • Status: Resolved
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
    • Target Version/s:

      Description

      After HDDS-682, volume creation through shell fails if the volume name does not have leading slash.

      $ ./ozone sh volume create volume1
      Volume name is required
      $ ./ozone sh volume create /volume1
      2018-10-30 14:07:58,078 INFO rpc.RpcClient: Creating Volume: volume1, with hdds as owner and quota set to 1152921504606846976 bytes.

      In OzoneAddress#stringToUri, when creating a new URI, the path parameter is expected to have a leading slash. Otherwise, the path gets mixed with the authority.

      To fix this, we should add a leading slash to the path variable, if it does not exist, before constructing the URI object.

        Attachments

        1. HDDS-766.001.patch
          0.8 kB
          chencan
        2. HDDS-766.003.patch
          2 kB
          chencan
        3. HDDS-766.004.patch
          1 kB
          chencan

          Issue Links

            Activity

              People

              • Assignee:
                candychencan chencan
                Reporter:
                hanishakoneru Hanisha Koneru
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:
                  Resolved: