private Text getKey(Path path) {
      int level = conf.getInt(NUMBER_OF_LEVELS_TO_PRESERVE_KEY, 1);
      int count = 0;
      String relPath = "";
      while (count++ < level) {
        relPath = Path.SEPARATOR + path.getName() + relPath;
        path = path.getParent();
      }
      return new Text(relPath);
    }
Extends DistCp for progress updating to backup system table during backup. Using DistCpV2
(MAPREDUCE-2765). Simply extend it and override execute() method to get the Job reference for
progress updating. Only the argument "src1, [src2, [...]] dst" is supported, no more DistCp
options.
hbase-backup/src/main/java/org/apache/hadoop/hbase/backup/mapreduce/MapReduceBackupCopyJob.java