ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From akovale...@apache.org
Subject git commit: AMBARI-5105. Mirroring: each instance is shown twice. (akovalenko)
Date Mon, 17 Mar 2014 13:34:13 GMT
Repository: ambari
Updated Branches:
  refs/heads/trunk d3e0602c4 -> 4a288fbac


AMBARI-5105. Mirroring: each instance is shown twice. (akovalenko)


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

Branch: refs/heads/trunk
Commit: 4a288fbac0cc38d60473c8ba11c26ffba31da664
Parents: d3e0602
Author: Aleksandr Kovalenko <akovalenko@hortonworks.com>
Authored: Mon Mar 17 15:31:58 2014 +0200
Committer: Aleksandr Kovalenko <akovalenko@hortonworks.com>
Committed: Mon Mar 17 15:31:58 2014 +0200

----------------------------------------------------------------------
 .../app/controllers/main/mirroring_controller.js  | 18 ++++++++++--------
 1 file changed, 10 insertions(+), 8 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/4a288fba/ambari-web/app/controllers/main/mirroring_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/main/mirroring_controller.js b/ambari-web/app/controllers/main/mirroring_controller.js
index dd8cdf0..c515048 100644
--- a/ambari-web/app/controllers/main/mirroring_controller.js
+++ b/ambari-web/app/controllers/main/mirroring_controller.js
@@ -168,14 +168,16 @@ App.MainMirroringController = Em.ArrayController.extend({
     if (data && data.instances) {
       var datasetJobs = [];
       data.instances.forEach(function (instance) {
-        datasetJobs.push({
-          dataset: opts.dataset,
-          id: instance.instance + '_' + opts.dataset,
-          name: instance.instance,
-          status: instance.status,
-          endTime: new Date(instance.endTime).getTime(),
-          startTime: new Date(instance.startTime).getTime()
-        });
+        if (instance.cluster == App.get('clusterName')) {
+          datasetJobs.push({
+            dataset: opts.dataset,
+            id: instance.instance + '_' + opts.dataset,
+            name: instance.instance,
+            status: instance.status,
+            endTime: new Date(instance.endTime).getTime(),
+            startTime: new Date(instance.startTime).getTime()
+          });
+        }
       }, this);
       datasetsData.findProperty('name', opts.dataset).set('instances', datasetJobs);
     }


Mime
View raw message