private boolean isPathWithinSubtree(Path path, HashMap<String, Boolean> parentPaths) {
    boolean response = false;
    for (Map.Entry<String, Boolean> parent : parentPaths.entrySet()) {
      if (!StringUtils.isEmpty(parent.getKey())) {
        response = FileUtils.isPathWithinSubtree(path, new Path(parent.getKey()));
      }
      if (response) {
        parent.setValue(true);
        break;
      }
    }
    return response;
  }
Creates copy task for the paths configured, irrespective of which table/partition belongs to it.
@param singlePathLocations paths to be copied. if the value is true then only the task is created.
@param fileList the tracking file which maintains the list of tasks.
@param conf Hive Configuration.
@throws Exception in case of any error.
ql/src/java/org/apache/hadoop/hive/ql/exec/repl/ReplExternalTables.java