瀏覽代碼

HADOOP-3808. Modified HOD to include RPC port of the JobTracker into the notes attribute of the resource manager. Contributed by Hemanth Yamijala.

git-svn-id: https://svn.apache.org/repos/asf/hadoop/core/trunk@679286 13f79535-47bb-0310-9956-ffa450edef68
Hemanth Yamijala 17 年之前
父節點
當前提交
c0bc20f668
共有 3 個文件被更改,包括 6 次插入1 次删除
  1. 3 0
      src/contrib/hod/CHANGES.txt
  2. 2 0
      src/contrib/hod/hodlib/Hod/hadoop.py
  3. 1 1
      src/contrib/hod/hodlib/Hod/nodePool.py

+ 3 - 0
src/contrib/hod/CHANGES.txt

@@ -29,6 +29,9 @@ Release 0.18.0 - Unreleased
     HADOOP-3610. Modified HOD to create cluster directory if one does not
     HADOOP-3610. Modified HOD to create cluster directory if one does not
     exist when using the script option. (Vinod Kumar Vavilapalli via yhemanth)
     exist when using the script option. (Vinod Kumar Vavilapalli via yhemanth)
 
 
+    HADOOP-3808. Modified HOD to include RPC port of the JobTracker
+    into the notes attribute of the resource manager. (yhemanth)
+
   NEW FEATURES
   NEW FEATURES
 
 
   IMPROVEMENTS
   IMPROVEMENTS

+ 2 - 0
src/contrib/hod/hodlib/Hod/hadoop.py

@@ -509,6 +509,8 @@ class hadoopCluster:
                     workerInfoMap = {}
                     workerInfoMap = {}
                     workerInfoMap['HDFS UI'] = 'http://%s' % self.hdfsInfo
                     workerInfoMap['HDFS UI'] = 'http://%s' % self.hdfsInfo
                     workerInfoMap['Mapred UI'] = 'http://%s' % self.mapredInfo
                     workerInfoMap['Mapred UI'] = 'http://%s' % self.mapredInfo
+                    if mapredAddr.find(':') != -1:
+                      workerInfoMap['Mapred RPC Port'] = mapredAddr.split(':')[1]
                     ret = self.__nodePool.updateWorkerInfo(workerInfoMap, self.jobId)
                     ret = self.__nodePool.updateWorkerInfo(workerInfoMap, self.jobId)
                     if ret != 0:
                     if ret != 0:
                       self.__log.warn('Could not update HDFS and Mapred information.' \
                       self.__log.warn('Could not update HDFS and Mapred information.' \

+ 1 - 1
src/contrib/hod/hodlib/Hod/nodePool.py

@@ -112,7 +112,7 @@ class NodePool:
     """Check if job can run by looking at any user/job limits"""
     """Check if job can run by looking at any user/job limits"""
     raise NotImplementedError
     raise NotImplementedError
 
 
-  def updateWorkerInfo(self, workerInfoMap):
+  def updateWorkerInfo(self, workerInfoMap, jobId):
     """Update information about the workers started by this NodePool."""
     """Update information about the workers started by this NodePool."""
     raise NotImplementedError
     raise NotImplementedError