Explorar o código

AMBARI-2459. HBase health status incorrectly showing down (red) when HBase master is up. (jaimin)

git-svn-id: https://svn.apache.org/repos/asf/incubator/ambari/trunk@1495518 13f79535-47bb-0310-9956-ffa450edef68
Jaimin Jetly %!s(int64=12) %!d(string=hai) anos
pai
achega
4e063f58c2

+ 1 - 1
ambari-web/app/models/service.js

@@ -59,7 +59,7 @@ App.Service = DS.Model.extend({
       this.set('healthStatus', 'red-blinking');
     }
 
-    if (this.get('serviceName') === 'HBASE') {
+    if (this.get('serviceName') === 'HBASE' && App.supports.multipleHBaseMasters) {
       var active = this.get('hostComponents').findProperty('haStatus', 'active');
       if (!active) {
         this.set('healthStatus', 'red');

+ 9 - 5
ambari-web/app/views/common/quick_view_link_view.js

@@ -33,14 +33,18 @@ App.QuickViewLinks = Em.View.extend({
     } else if (serviceName === 'MAPREDUCE') {
       host = App.singleNodeInstall ? App.singleNodeAlias : components.findProperty('componentName', 'JOBTRACKER').get('host.publicHostName');
     } else if (serviceName === 'HBASE') {
-      var component = components.filterProperty('componentName', 'HBASE_MASTER').findProperty('haStatus', 'active');
-      if(component){
-        if(App.singleNodeInstall){
+      var component;
+      if (App.supports.multipleHBaseMasters) {
+        component = components.filterProperty('componentName', 'HBASE_MASTER').findProperty('haStatus', 'active');
+      } else {
+        component = components.findProperty('componentName', 'HBASE_MASTER');
+      }
+      if (component) {
+        if (App.singleNodeInstall) {
           host = App.singleNodeAlias;
-        }else{
+        } else {
           host = component.get('host.publicHostName');
         }
-
       }
     }
     if (!host) {