public class FileOutputCommitter extends OutputCommitter
OutputCommitter that commits files specified
in job output directory i.e. ${mapred.output.dir}.| 限定符和类型 | 字段和说明 |
|---|---|
static org.apache.commons.logging.Log |
LOG |
static String |
SUCCEEDED_FILE_NAME |
static String |
TEMP_DIR_NAME
Temporary directory name
|
| 构造器和说明 |
|---|
FileOutputCommitter() |
| 限定符和类型 | 方法和说明 |
|---|---|
void |
abortJob(JobContext context,
int runState)
Delete the temporary directory, including all of the work directories.
|
void |
abortTask(TaskAttemptContext context)
Discard the task output
|
void |
cleanupJob(JobContext context)
已过时。
|
void |
commitJob(JobContext context)
For committing job's output after successful job completion.
|
void |
commitTask(TaskAttemptContext context)
To promote the task's temporary output to final output location
The task's output is moved to the job's output directory.
|
boolean |
needsTaskCommit(TaskAttemptContext context)
Check whether task needs a commit
|
void |
setupJob(JobContext context)
For the framework to setup the job output during initialization
|
void |
setupTask(TaskAttemptContext context)
Sets up output for the task.
|
abortJob, abortTask, cleanupJob, commitJob, commitTask, needsTaskCommit, setupJob, setupTaskpublic void setupJob(JobContext context) throws IOException
OutputCommittersetupJob 在类中 OutputCommittercontext - Context of the job whose output is being written.IOException - if temporary output could not be createdpublic void commitJob(JobContext context) throws IOException
OutputCommitterJobStatus.SUCCEEDED.commitJob 在类中 OutputCommittercontext - Context of the job whose output is being written.IOException@Deprecated public void cleanupJob(JobContext context) throws IOException
OutputCommittercleanupJob 在类中 OutputCommitterIOExceptionpublic void abortJob(JobContext context, int runState) throws IOException
abortJob 在类中 OutputCommittercontext - the job's contextrunState - final run state of the job, should be
JobStatus.KILLED or JobStatus.FAILEDIOExceptionpublic void setupTask(TaskAttemptContext context) throws IOException
OutputCommittersetupTask 在类中 OutputCommittercontext - Context of the task whose output is being written.IOExceptionpublic void commitTask(TaskAttemptContext context) throws IOException
OutputCommittercommitTask 在类中 OutputCommittercontext - Context of the task whose output is being written.IOException - if commit is notpublic void abortTask(TaskAttemptContext context) throws IOException
OutputCommitterabortTask 在类中 OutputCommitterIOExceptionpublic boolean needsTaskCommit(TaskAttemptContext context) throws IOException
OutputCommitterneedsTaskCommit 在类中 OutputCommitterIOExceptionCopyright © 2009 The Apache Software Foundation