From 3943008b073e5eef16dcb8e1525320dcac26095e Mon Sep 17 00:00:00 2001 From: Jason Darrell Lowe Date: Tue, 15 Jan 2013 14:49:14 +0000 Subject: [PATCH] svn merge -c 1433445 FIXES: MAPREDUCE-4936. JobImpl uber checks for cpu are wrong. Contributed by Arun C Murthy git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/branches/branch-2@1433446 13f79535-47bb-0310-9956-ffa450edef68 --- hadoop-mapreduce-project/CHANGES.txt | 3 +++ .../hadoop/mapreduce/v2/app/job/impl/JobImpl.java | 10 +++++++--- 2 files changed, 10 insertions(+), 3 deletions(-) diff --git a/hadoop-mapreduce-project/CHANGES.txt b/hadoop-mapreduce-project/CHANGES.txt index 68f1e3f9c42..b7e98b4c4d0 100644 --- a/hadoop-mapreduce-project/CHANGES.txt +++ b/hadoop-mapreduce-project/CHANGES.txt @@ -94,6 +94,9 @@ Release 2.0.3-alpha - Unreleased MAPREDUCE-1700. User supplied dependencies may conflict with MapReduce system JARs. (tomwhite) + MAPREDUCE-4936. JobImpl uber checks for cpu are wrong (Arun C Murthy via + jlowe) + Release 2.0.2-alpha - 2012-09-07 INCOMPATIBLE CHANGES diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/job/impl/JobImpl.java b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/job/impl/JobImpl.java index 7306cda792b..bf5e96ce1c2 100644 --- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/job/impl/JobImpl.java +++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/job/impl/JobImpl.java @@ -1068,9 +1068,13 @@ public class JobImpl implements org.apache.hadoop.mapreduce.v2.app.job.Job, boolean smallCpu = ( Math.max( - conf.getInt(MRJobConfig.MAP_CPU_VCORES, 1), - conf.getInt(MRJobConfig.REDUCE_CPU_VCORES, 1)) < - sysCPUSizeForUberSlot + conf.getInt( + MRJobConfig.MAP_CPU_VCORES, + MRJobConfig.DEFAULT_MAP_CPU_VCORES), + conf.getInt( + MRJobConfig.REDUCE_CPU_VCORES, + MRJobConfig.DEFAULT_REDUCE_CPU_VCORES)) + <= sysCPUSizeForUberSlot ); boolean notChainJob = !isChainJob(conf);