incubator-ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vik...@apache.org
Subject svn commit: r1347200 - in /incubator/ambari/branches/ambari-186: CHANGES.txt hmc/js/clustersList.js
Date Wed, 06 Jun 2012 23:15:33 GMT
Author: vikram
Date: Wed Jun  6 23:15:33 2012
New Revision: 1347200

URL: http://svn.apache.org/viewvc?rev=1347200&view=rev
Log:
AMBARI-530. HMC UI shows undefined for nodes after single node install  (Contributed by Yusaku)

Modified:
    incubator/ambari/branches/ambari-186/CHANGES.txt
    incubator/ambari/branches/ambari-186/hmc/js/clustersList.js

Modified: incubator/ambari/branches/ambari-186/CHANGES.txt
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/ambari-186/CHANGES.txt?rev=1347200&r1=1347199&r2=1347200&view=diff
==============================================================================
--- incubator/ambari/branches/ambari-186/CHANGES.txt (original)
+++ incubator/ambari/branches/ambari-186/CHANGES.txt Wed Jun  6 23:15:33 2012
@@ -6,6 +6,8 @@ characters wide.
 
 Release 0.1.x - unreleased
 
+  AMBARI-530. HMC UI shows undefined for nodes after single node install (Yusaku via Vikram)
+
   AMBARI-532. add ganglia monitor to all masters (Mahadev via Vikram)
 
   AMBARI-407. add more logging and timing info for various actions (Hitesh via Vikram)

Modified: incubator/ambari/branches/ambari-186/hmc/js/clustersList.js
URL: http://svn.apache.org/viewvc/incubator/ambari/branches/ambari-186/hmc/js/clustersList.js?rev=1347200&r1=1347199&r2=1347200&view=diff
==============================================================================
--- incubator/ambari/branches/ambari-186/hmc/js/clustersList.js (original)
+++ incubator/ambari/branches/ambari-186/hmc/js/clustersList.js Wed Jun  6 23:15:33 2012
@@ -9,12 +9,15 @@ function populateHostToMasterRoleMapping
 
         globalYui.Array.each( clusterServices[serviceName].components, function (serviceComponent)
{
           if (serviceComponent.isMaster) {
-            // just add the client to the hostname object
-            if ( !( serviceComponent.hostName in hostMap ) ) {
-              hostMap[serviceComponent.hostName] = new Array();
-              hostMap[serviceComponent.hostName].push({ serviceName: serviceComponent.displayName,
isMaster: true });
-            } else {
-              hostMap[serviceComponent.hostName].push({ serviceName: serviceComponent.displayName,
isMaster: true});
+            // just add the master to the hostname object
+            for (var i in serviceComponent.hostNames) {
+              var hostName = serviceComponent.hostNames[i];
+              if ( !( hostName in hostMap ) ) {
+                hostMap[hostName] = new Array();
+                hostMap[hostName].push({ serviceName: serviceComponent.displayName, isMaster:
true });
+              } else {
+                hostMap[hostName].push({ serviceName: serviceComponent.displayName, isMaster:
true });
+              }
             }
           }
         });
@@ -34,11 +37,14 @@ function populateHostToClientRoleMapping
         globalYui.Array.each( clusterServices[serviceName].components, function (serviceComponent)
{          
           if (serviceComponent.isClient) {
             // just add the client to the hostname object
-            if ( !( serviceComponent.hostName in hostMap ) ) {
-              hostMap[serviceComponent.hostName] = new Array();
-              hostMap[serviceComponent.hostName].push({ serviceName: serviceComponent.displayName,
isMaster: false });
-            } else {
-              hostMap[serviceComponent.hostName].push({ serviceName: serviceComponent.displayName,
isMaster: false });
+            for (var i in serviceComponent.hostNames) {
+              var hostName = serviceComponent.hostNames[i];
+              if ( !( hostName in hostMap ) ) {
+                hostMap[hostName] = new Array();
+                hostMap[hostName].push({ serviceName: serviceComponent.displayName, isMaster:
false });
+              } else {
+                hostMap[hostName].push({ serviceName: serviceComponent.displayName, isMaster:
false });
+              }
             }
           }
         });



Mime
View raw message