Browse Source

AMBARI-4776. Falcon: Add Quick Links menu pointing to Falcon Web UI. (xiwang via yusaku)

Yusaku Sako 11 years ago
parent
commit
77e37961ed

+ 2 - 1
ambari-web/app/mappers/service_metrics_mapper.js

@@ -314,7 +314,8 @@ App.serviceMetricsMapper = App.QuickDataMapper.create({
       GANGLIA: [20],
       NAGIOS: [21],
       HUE: [22],
-      STORM: [31]
+      STORM: [31],
+      FALCON: [32]
     };
     if (quickLinks[item.ServiceInfo.service_name])
       finalJson.quick_links = quickLinks[item.ServiceInfo.service_name];

+ 12 - 0
ambari-web/app/models/quick_links.js

@@ -400,5 +400,17 @@ App.QuickLinks.FIXTURES = [
     site: 'storm-site',
     regex: portRegex,
     default_http_port: 8744
+  },
+  {
+    id:32,
+    label:'Falcon Web UI',
+    url:'%@://%@:%@/',
+    service_id: 'FALCON',
+    template:'%@://%@:%@/',
+    http_config: 'falconserver.host',
+    https_config: 'falconserver.host',
+    site: 'oozie-site',
+    regex: portRegex,
+    default_http_port: 15000
   }
 ];

+ 3 - 0
ambari-web/app/models/service_config.js

@@ -406,6 +406,9 @@ App.ServiceConfigProperty = Ember.Object.extend({
       case 'nimbus.host':
         this.set('value', masterComponentHostsInDB.findProperty('component', 'NIMBUS').hostName);
         break;
+      case 'falconserver.host':
+        this.set('value', masterComponentHostsInDB.findProperty('component', 'FALCON_SERVER').hostName);
+        break;
       case 'logviewerserver_host':
         this.set('value', masterComponentHostsInDB.findProperty('component', 'LOGVIEWER_SERVER').hostName);
         break;

+ 1 - 0
ambari-web/app/views/common/quick_view_link_view.js

@@ -244,6 +244,7 @@ App.QuickViewLinks = Em.View.extend({
       case "nagios":
       case "hue":
       case "storm":
+      case "falcon":
         return "_blank";
         break;
       default: