Pārlūkot izejas kodu

MAPREDUCE-5751. MR app master fails to start in some cases if mapreduce.job.classloader is true. Contributed by Sangjin Lee

git-svn-id: https://svn.apache.org/repos/asf/hadoop/common/trunk@1577554 13f79535-47bb-0310-9956-ffa450edef68
Jason Darrell Lowe 11 gadi atpakaļ
vecāks
revīzija
0ab1f90d40

+ 3 - 0
hadoop-mapreduce-project/CHANGES.txt

@@ -234,6 +234,9 @@ Release 2.4.0 - UNRELEASED
     MAPREDUCE-5794. SliveMapper always uses default FileSystem. (szetszwo via
     Arpit Agarwal)
 
+    MAPREDUCE-5751. MR app master fails to start in some cases if
+    mapreduce.job.classloader is true (Sangjin Lee via jlowe)
+
 Release 2.3.1 - UNRELEASED
 
   INCOMPATIBLE CHANGES

+ 2 - 2
hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-app/src/main/java/org/apache/hadoop/mapreduce/v2/app/MRAppMaster.java

@@ -1080,6 +1080,8 @@ public class MRAppMaster extends CompositeService {
     //start all the components
     super.serviceStart();
 
+    // set job classloader if configured
+    MRApps.setJobClassLoader(getConfig());
     // All components have started, start the job.
     startJobs();
   }
@@ -1396,8 +1398,6 @@ public class MRAppMaster extends CompositeService {
       // SIGTERM I have a chance to write out the job history. I'll be closing
       // the objects myself.
       conf.setBoolean("fs.automatic.close", false);
-      // set job classloader if configured
-      MRApps.setJobClassLoader(conf);
       initAndStartAppMaster(appMaster, conf, jobUserName);
     } catch (Throwable t) {
       LOG.fatal("Error starting MRAppMaster", t);