List of usage examples for org.apache.hadoop.mapred OutputCommitter needsTaskCommit
@Override public final boolean needsTaskCommit(org.apache.hadoop.mapreduce.TaskAttemptContext taskContext) throws IOException
From source file:org.apache.ignite.internal.processors.hadoop.impl.v1.HadoopV1OutputCollector.java
License:Apache License
/** * Commit task.//from www . j a v a 2s. co m * * @throws IOException In failed. */ public void commit() throws IOException { if (writer != null) { OutputCommitter outputCommitter = jobConf.getOutputCommitter(); TaskAttemptContext taskCtx = new TaskAttemptContextImpl(jobConf, attempt); if (outputCommitter.needsTaskCommit(taskCtx)) outputCommitter.commitTask(taskCtx); } }