use of org.apache.hadoop.hive.metastore.api.CmRecycleRequest in project hive by apache.
the class Hive method recycleDirToCmPath.
/**
* Recycles the files recursively from the input path to the cmroot directory either by copying or moving it.
*
* @param dataPath Path of the data files to be recycled to cmroot
* @param isPurge
* When set to true files which needs to be recycled are not moved to Trash
*/
public void recycleDirToCmPath(Path dataPath, boolean isPurge) throws HiveException {
try {
CmRecycleRequest request = new CmRecycleRequest(dataPath.toString(), isPurge);
getSynchronizedMSC().recycleDirToCmPath(request);
} catch (Exception e) {
throw new HiveException(e);
}
}
Aggregations