K
- V
- public class CopyOutputFormat<K,V> extends TextOutputFormat<K,V>
TextOutputFormat.LineRecordWriter<K,V>
FileOutputFormat.Counter
BASE_OUTPUT_NAME, PART
构造器和说明 |
---|
CopyOutputFormat() |
限定符和类型 | 方法和说明 |
---|---|
void |
checkOutputSpecs(JobContext context)
Check for validity of the output-specification for the job.
|
static Path |
getCommitDirectory(Job job)
Getter for the final commit-directory.
|
OutputCommitter |
getOutputCommitter(TaskAttemptContext context)
Get the output committer for this output format.
|
static Path |
getWorkingDirectory(Job job)
Getter for the working directory.
|
static void |
setCommitDirectory(Job job,
Path commitDirectory)
Setter for the final directory for DistCp (where files copied will be
moved, atomically.)
|
static void |
setWorkingDirectory(Job job,
Path workingDirectory)
Setter for the working directory for DistCp (where files will be copied
before they are moved to the final commit-directory.)
|
getRecordWriter
getCompressOutput, getDefaultWorkFile, getOutputCompressorClass, getOutputName, getOutputPath, getPathForWorkFile, getUniqueFile, getWorkOutputPath, setCompressOutput, setOutputCompressorClass, setOutputName, setOutputPath
public static void setWorkingDirectory(Job job, Path workingDirectory)
job
- The Job on whose configuration the working-directory is to be set.workingDirectory
- The path to use as the working directory.public static void setCommitDirectory(Job job, Path commitDirectory)
job
- The Job on whose configuration the working-directory is to be set.commitDirectory
- The path to use for final commit.public static Path getWorkingDirectory(Job job)
job
- The Job from whose configuration the working-directory is to
be retrieved.public static Path getCommitDirectory(Job job)
job
- The Job from whose configuration the commit-directory is to be
retrieved.public OutputCommitter getOutputCommitter(TaskAttemptContext context) throws IOException
OutputFormat
getOutputCommitter
在类中 FileOutputFormat<K,V>
context
- the task contextIOException
public void checkOutputSpecs(JobContext context) throws IOException
OutputFormat
This is to validate the output specification for the job when it is a job is submitted. Typically checks that it does not already exist, throwing an exception when it already exists, so that output is not overwritten.
checkOutputSpecs
在类中 FileOutputFormat<K,V>
context
- information about the jobIOException
- when output should not be attemptedCopyright © 2009 The Apache Software Foundation