You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by at...@apache.org on 2015/03/03 15:20:07 UTC

[1/2] ambari git commit: AMBARI-9887 400-node cluster: Hosts page become unresponsive. (atkach)

Repository: ambari
Updated Branches:
  refs/heads/trunk 087b990aa -> c313023bd


AMBARI-9887 400-node cluster: Hosts page become unresponsive. (atkach)


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

Branch: refs/heads/trunk
Commit: d27807b145d2d6c58eb5b1b7ed23e60b172ff119
Parents: 087b990
Author: Andrii Tkach <at...@hortonworks.com>
Authored: Tue Mar 3 13:24:01 2015 +0200
Committer: Andrii Tkach <at...@hortonworks.com>
Committed: Tue Mar 3 16:19:11 2015 +0200

----------------------------------------------------------------------
 ambari-web/app/mappers/hosts_mapper.js |  2 ++
 ambari-web/app/views/main/host.js      | 12 +-----------
 2 files changed, 3 insertions(+), 11 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/d27807b1/ambari-web/app/mappers/hosts_mapper.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/mappers/hosts_mapper.js b/ambari-web/app/mappers/hosts_mapper.js
index 9013d12..5af2dae 100644
--- a/ambari-web/app/mappers/hosts_mapper.js
+++ b/ambari-web/app/mappers/hosts_mapper.js
@@ -88,6 +88,7 @@ App.hostsMapper = App.QuickDataMapper.create({
       var cacheServices = App.cache['services'];
       var loadedServiceComponentsMap = App.get('componentConfigMapper').buildServiceComponentMap(cacheServices);
       var serviceToHostComponentIdMap = {};
+      var selectedHosts = App.db.getSelectedHosts('mainHostController');
 
       json.items.forEach(function (item, index) {
         item.host_components = item.host_components || [];
@@ -130,6 +131,7 @@ App.hostsMapper = App.QuickDataMapper.create({
         }
         var parsedItem = this.parseIt(item, this.config);
         parsedItem.is_requested = true;
+        parsedItem.selected = selectedHosts.contains(parsedItem.host_name);
 
         hostIds[item.Hosts.host_name] = parsedItem;
 

http://git-wip-us.apache.org/repos/asf/ambari/blob/d27807b1/ambari-web/app/views/main/host.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/host.js b/ambari-web/app/views/main/host.js
index 7f49486..fd91cf8 100644
--- a/ambari-web/app/views/main/host.js
+++ b/ambari-web/app/views/main/host.js
@@ -52,17 +52,7 @@ App.MainHostView = App.TableView.extend(App.TableServerViewMixin, {
    * List of hosts in cluster
    * @type {Array}
    */
-  content: function () {
-    var controllerName = this.get('controller.name');
-    var selectedHosts = App.db.getSelectedHosts(controllerName);
-    if (this.get('controller')) {
-      return this.get('controller.content').filter(function (host) {
-        host.set('selected', selectedHosts.contains(host.get('hostName')));
-        return true;
-      });
-    }
-    return [];
-  }.property('controller.content'),
+  contentBinding: 'controller.content',
 
   onRequestErrorHandler: function() {
     this.set('requestError', null);


[2/2] ambari git commit: AMBARI-9888 Hosts status filter broken. (atkach)

Posted by at...@apache.org.
AMBARI-9888 Hosts status filter broken. (atkach)


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

Branch: refs/heads/trunk
Commit: c313023bd25d4a0fc1d23be5b6b1931638feb20c
Parents: d27807b
Author: Andrii Tkach <at...@hortonworks.com>
Authored: Tue Mar 3 13:53:26 2015 +0200
Committer: Andrii Tkach <at...@hortonworks.com>
Committed: Tue Mar 3 16:19:14 2015 +0200

----------------------------------------------------------------------
 ambari-web/app/views/main/host.js | 9 +++++++++
 1 file changed, 9 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/c313023b/ambari-web/app/views/main/host.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/views/main/host.js b/ambari-web/app/views/main/host.js
index fd91cf8..f2d4002 100644
--- a/ambari-web/app/views/main/host.js
+++ b/ambari-web/app/views/main/host.js
@@ -798,6 +798,15 @@ App.MainHostView = App.TableView.extend(App.TableServerViewMixin, {
         this.get('parentView').updateFilter(category.get('column'), category.get('filterValue'), category.get('type'));
       }
     },
+
+    /**
+     * set value
+     * @param {string} value
+     */
+    setValue: function (value) {
+      this.set('value', value);
+    },
+
     clearFilter: function() {
       this.get('categories').setEach('isActive', false);
       this.set('value', '');