Author: yusaku
Date: Sat Jan 19 01:22:27 2013
New Revision: 1435440
URL: http://svn.apache.org/viewvc?rev=1435440&view=rev
Log:
AMBARI-1219. After adding hosts, the number of live TaskTrackers is not
updated. (yusaku)
Modified:
incubator/ambari/trunk/CHANGES.txt
incubator/ambari/trunk/ambari-web/app/mappers/service_mapper.js
Modified: incubator/ambari/trunk/CHANGES.txt
URL:
http://svn.apache.org/viewvc/incubator/ambari/trunk/CHANGES.txt?rev=1435440&r1=1435439&r2=1435440&view=diff
==============================================================================
--- incubator/ambari/trunk/CHANGES.txt (original)
+++ incubator/ambari/trunk/CHANGES.txt Sat Jan 19 01:22:27 2013
@@ -60,6 +60,9 @@ Trunk (unreleased changes):
BUG FIXES
+ AMBARI-1219. After adding hosts, the number of live TaskTrackers is not
+ updated. (yusaku)
+
AMBARI-1176. In some cases, once Add Hosts wizard has run once, it requires
a log out before the Add Hosts wizard can be run again. (yusaku)
Modified: incubator/ambari/trunk/ambari-web/app/mappers/service_mapper.js
URL:
http://svn.apache.org/viewvc/incubator/ambari/trunk/ambari-web/app/mappers/service_mapper.js?rev=1435440&r1=1435439&r2=1435440&view=diff
==============================================================================
--- incubator/ambari/trunk/ambari-web/app/mappers/service_mapper.js (original)
+++ incubator/ambari/trunk/ambari-web/app/mappers/service_mapper.js Sat Jan 19
01:22:27 2013
@@ -289,6 +289,23 @@ App.servicesMapper = App.QuickDataMapper
e.set("reducesRunning", finalJson.reduces_running);
e.set("reducesWaiting", finalJson.reduces_waiting);
e.set("trackersDecommissioned", finalJson.trackers_decommissioned);
+
+ var taskTrackers = e.get('taskTrackers');
+ if (taskTrackers) {
+ taskTrackers.clear();
+ finalJson.task_trackers.forEach(function (ldn) {
+ taskTrackers.pushObject(App.Host.find(ldn));
+ });
+ }
+
+ taskTrackers = e.get('aliveTrackers');
+ if (taskTrackers) {
+ taskTrackers.clear();
+ finalJson.alive_trackers.forEach(function (ldn) {
+ taskTrackers.pushObject(App.Host.find(ldn));
+ });
+ }
+
})
break;
case 'HBASE':
@@ -302,6 +319,15 @@ App.servicesMapper = App.QuickDataMapper
e.set("revision", finalJson.revision);
e.set("heapMemoryUsed", finalJson.heap_memory_used);
e.set("heapMemoryMax", finalJson.heap_memory_max);
+
+ var regionServers = e.get('regionServers');
+ if (regionServers) {
+ regionServers.clear();
+ finalJson.region_servers.forEach(function (ldn) {
+ regionServers.pushObject(App.Host.find(ldn));
+ });
+ }
+
})
break;
default: