hadoop-common-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From ha...@apache.org
Subject hadoop git commit: MAPREDUCE-4414. Add main methods to JobConf and YarnConfiguration, for debug purposes. Contributed by Plamen Jeliazkov.
Date Mon, 16 Mar 2015 19:32:53 GMT
Repository: hadoop
Updated Branches:
  refs/heads/branch-2 eb4eb63de -> 2684b0b44


MAPREDUCE-4414. Add main methods to JobConf and YarnConfiguration, for debug purposes. Contributed
by Plamen Jeliazkov.

(cherry picked from commit 571f75b468a4412be2178466cb5d3888b05cd076)


Project: http://git-wip-us.apache.org/repos/asf/hadoop/repo
Commit: http://git-wip-us.apache.org/repos/asf/hadoop/commit/2684b0b4
Tree: http://git-wip-us.apache.org/repos/asf/hadoop/tree/2684b0b4
Diff: http://git-wip-us.apache.org/repos/asf/hadoop/diff/2684b0b4

Branch: refs/heads/branch-2
Commit: 2684b0b440f52212e8cf75fda4075590f21059d0
Parents: eb4eb63
Author: Harsh J <harsh@cloudera.com>
Authored: Tue Mar 17 01:01:06 2015 +0530
Committer: Harsh J <harsh@cloudera.com>
Committed: Tue Mar 17 01:02:21 2015 +0530

----------------------------------------------------------------------
 hadoop-mapreduce-project/CHANGES.txt                            | 3 +++
 .../src/main/java/org/apache/hadoop/mapred/JobConf.java         | 5 +++++
 .../java/org/apache/hadoop/yarn/conf/YarnConfiguration.java     | 5 +++++
 3 files changed, 13 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/hadoop/blob/2684b0b4/hadoop-mapreduce-project/CHANGES.txt
----------------------------------------------------------------------
diff --git a/hadoop-mapreduce-project/CHANGES.txt b/hadoop-mapreduce-project/CHANGES.txt
index 2a79395..5feb14d 100644
--- a/hadoop-mapreduce-project/CHANGES.txt
+++ b/hadoop-mapreduce-project/CHANGES.txt
@@ -8,6 +8,9 @@ Release 2.8.0 - UNRELEASED
 
   IMPROVEMENTS
 
+    MAPREDUCE-4414. Add main methods to JobConf and YarnConfiguration,
+    for debug purposes. (Plamen Jeliazkov via harsh)
+
   OPTIMIZATIONS
 
   BUG FIXES

http://git-wip-us.apache.org/repos/asf/hadoop/blob/2684b0b4/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobConf.java
----------------------------------------------------------------------
diff --git a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobConf.java
b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobConf.java
index 51b99be..c2bb1d5 100644
--- a/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobConf.java
+++ b/hadoop-mapreduce-project/hadoop-mapreduce-client/hadoop-mapreduce-client-core/src/main/java/org/apache/hadoop/mapred/JobConf.java
@@ -2021,5 +2021,10 @@ public class JobConf extends Configuration {
   }
   
 
+  /* For debugging. Dump configurations to system output as XML format. */
+  public static void main(String[] args) throws Exception {
+    new JobConf(new Configuration()).writeXml(System.out);
+  }
+
 }
 

http://git-wip-us.apache.org/repos/asf/hadoop/blob/2684b0b4/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/conf/YarnConfiguration.java
----------------------------------------------------------------------
diff --git a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/conf/YarnConfiguration.java
b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/conf/YarnConfiguration.java
index f6ebb51..be5471d 100644
--- a/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/conf/YarnConfiguration.java
+++ b/hadoop-yarn-project/hadoop-yarn/hadoop-yarn-api/src/main/java/org/apache/hadoop/yarn/conf/YarnConfiguration.java
@@ -1808,4 +1808,9 @@ public class YarnConfiguration extends Configuration {
     }
     return clusterId;
   }
+
+  /* For debugging. mp configurations to system output as XML format. */
+  public static void main(String[] args) throws Exception {
+    new YarnConfiguration(new Configuration()).writeXml(System.out);
+  }
 }


Mime
View raw message