MAPREDUCE-3181. Fixed MapReduce runtime to load yarn-default.xml and yarn-site.xml.
git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1186458 13f79535-47bb-0310-9956-ffa450edef68
This commit is contained in:
parent
94e1703b72
commit
9473b2e43f
|
@ -1686,6 +1686,9 @@ Release 0.23.0 - Unreleased
|
||||||
MAPREDUCE-3176. Fixed ant mapreduce tests that are timing out because
|
MAPREDUCE-3176. Fixed ant mapreduce tests that are timing out because
|
||||||
of wrong framework name. (Hitesh Shah via vinodkv)
|
of wrong framework name. (Hitesh Shah via vinodkv)
|
||||||
|
|
||||||
|
MAPREDUCE-3181. Fixed MapReduce runtime to load yarn-default.xml and
|
||||||
|
yarn-site.xml. (acmurthy)
|
||||||
|
|
||||||
Release 0.22.0 - Unreleased
|
Release 0.22.0 - Unreleased
|
||||||
|
|
||||||
INCOMPATIBLE CHANGES
|
INCOMPATIBLE CHANGES
|
||||||
|
|
|
@ -40,6 +40,8 @@ public class ConfigUtil {
|
||||||
addDeprecatedKeys();
|
addDeprecatedKeys();
|
||||||
Configuration.addDefaultResource("mapred-default.xml");
|
Configuration.addDefaultResource("mapred-default.xml");
|
||||||
Configuration.addDefaultResource("mapred-site.xml");
|
Configuration.addDefaultResource("mapred-site.xml");
|
||||||
|
Configuration.addDefaultResource("yarn-default.xml");
|
||||||
|
Configuration.addDefaultResource("yarn-site.xml");
|
||||||
}
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
|
|
@ -29,7 +29,6 @@ import org.apache.hadoop.mapreduce.JobContext;
|
||||||
import org.apache.hadoop.mapreduce.OutputCommitter;
|
import org.apache.hadoop.mapreduce.OutputCommitter;
|
||||||
import org.apache.hadoop.mapreduce.RecordWriter;
|
import org.apache.hadoop.mapreduce.RecordWriter;
|
||||||
import org.apache.hadoop.mapreduce.TaskAttemptContext;
|
import org.apache.hadoop.mapreduce.TaskAttemptContext;
|
||||||
import org.apache.hadoop.mapreduce.TaskType;
|
|
||||||
import org.apache.hadoop.mapreduce.lib.output.FileOutputCommitter;
|
import org.apache.hadoop.mapreduce.lib.output.FileOutputCommitter;
|
||||||
import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat;
|
import org.apache.hadoop.mapreduce.lib.output.FileOutputFormat;
|
||||||
|
|
||||||
|
@ -100,28 +99,9 @@ public class TeraOutputFormat extends FileOutputFormat<Text,Text> {
|
||||||
throws IOException {
|
throws IOException {
|
||||||
if (committer == null) {
|
if (committer == null) {
|
||||||
Path output = getOutputPath(context);
|
Path output = getOutputPath(context);
|
||||||
committer = new TeraOutputCommitter(output, context);
|
committer = new FileOutputCommitter(output, context);
|
||||||
}
|
}
|
||||||
return committer;
|
return committer;
|
||||||
}
|
}
|
||||||
|
|
||||||
public static class TeraOutputCommitter extends FileOutputCommitter {
|
|
||||||
|
|
||||||
public TeraOutputCommitter(Path outputPath, TaskAttemptContext context)
|
|
||||||
throws IOException {
|
|
||||||
super(outputPath, context);
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void commitJob(JobContext jobContext) {
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void setupJob(JobContext jobContext) {
|
|
||||||
}
|
|
||||||
|
|
||||||
@Override
|
|
||||||
public void setupTask(TaskAttemptContext taskContext) {
|
|
||||||
}
|
|
||||||
}
|
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue