Class MapReduceBackupCopyJob.BackupDistCp
java.lang.Object
org.apache.hadoop.conf.Configured
org.apache.hadoop.tools.DistCp
org.apache.hadoop.hbase.backup.mapreduce.MapReduceBackupCopyJob.BackupDistCp
- All Implemented Interfaces:
org.apache.hadoop.conf.Configurable,org.apache.hadoop.util.Tool
- Enclosing class:
- MapReduceBackupCopyJob
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.
-
Field Summary
Fields -
Constructor Summary
ConstructorsConstructorDescriptionBackupDistCp(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.tools.DistCpOptions options, BackupInfo backupInfo, BackupManager backupManager) -
Method Summary
Modifier and TypeMethodDescriptionprotected org.apache.hadoop.fs.PathcreateInputFileListing(org.apache.hadoop.mapreduce.Job job) org.apache.hadoop.mapreduce.Jobexecute()private FieldgetInputOptionsField(Class<?> classDistCp) private org.apache.hadoop.io.TextgetKey(org.apache.hadoop.fs.Path path) private List<org.apache.hadoop.fs.Path>private List<org.apache.hadoop.fs.Path>getSourcePaths(Field fieldInputOptions) private org.apache.hadoop.io.SequenceFile.WritergetWriter(org.apache.hadoop.fs.Path pathToListFile) Methods inherited from class org.apache.hadoop.tools.DistCp
cleanup, createAndSubmitJob, getContext, getFileListingPath, main, run, waitForJobCompletionMethods inherited from class org.apache.hadoop.conf.Configured
getConf, setConfMethods inherited from class java.lang.Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface org.apache.hadoop.conf.Configurable
getConf, setConf
-
Field Details
-
backupInfo
-
backupManager
-
-
Constructor Details
-
BackupDistCp
public BackupDistCp(org.apache.hadoop.conf.Configuration conf, org.apache.hadoop.tools.DistCpOptions options, BackupInfo backupInfo, BackupManager backupManager) throws Exception - Throws:
Exception
-
-
Method Details
-
execute
- Overrides:
executein classorg.apache.hadoop.tools.DistCp- Throws:
Exception
-
getInputOptionsField
- Throws:
IOException
-
getSourcePaths
- Throws:
IOException
-
createInputFileListing
protected org.apache.hadoop.fs.Path createInputFileListing(org.apache.hadoop.mapreduce.Job job) throws IOException - Overrides:
createInputFileListingin classorg.apache.hadoop.tools.DistCp- Throws:
IOException
-
getKey
-
getSourceFiles
private List<org.apache.hadoop.fs.Path> getSourceFiles() throws NoSuchFieldException, SecurityException, IllegalArgumentException, IllegalAccessException, NoSuchMethodException, ClassNotFoundException, InvocationTargetException, IOException -
getWriter
private org.apache.hadoop.io.SequenceFile.Writer getWriter(org.apache.hadoop.fs.Path pathToListFile) throws IOException - Throws:
IOException
-