Uploaded image for project: 'HBase'
  1. HBase
  2. HBASE-22070

Checking restoreDir in RestoreSnapshotHelper

    XMLWordPrintableJSON

Details

    • Patch

    Description

      The restoreDir shouldn't be a sub directory of rootDir. The code check it with a prefix check "restoreDir.toUri().getPath().startsWith(rootDir.toUri().getPath())". But it goes error in some reasonable cases.

      eg: rootDir = hdfs://user/hbase restoreDir = hdfs://user/hbase_restore. So I think it's more reasonable to chang the code to "restoreDir.toUri().getPath().startsWith(rootDir.toUri().getPath() + "/" )".

      Attachments

        1. HBASE-22070-master-001.patch
          1 kB
          Peter Somogyi
        2. 0001-fixed-a-bug-of-checking-if-restoreDir-is-subDir-of-r.patch
          1 kB
          Vincent Choi
        3. HBASE-22070.patch
          0.9 kB
          Vincent Choi

        Activity

          People

            VincentChoiCN Vincent Choi
            VincentChoiCN Vincent Choi
            Votes:
            0 Vote for this issue
            Watchers:
            4 Start watching this issue

            Dates

              Created:
              Updated:
              Resolved: