diff options
Diffstat (limited to 'ambari-web/app/app.js')
-rw-r--r-- | ambari-web/app/app.js | 20 |
1 files changed, 18 insertions, 2 deletions
diff --git a/ambari-web/app/app.js b/ambari-web/app/app.js index 77bb21e55f..20ad4ac195 100644 --- a/ambari-web/app/app.js +++ b/ambari-web/app/app.js @@ -72,14 +72,14 @@ module.exports = Em.Application.create({ currentStackVersion: '', currentStackName: function() { return Em.get((this.get('currentStackVersion') || this.get('defaultStackVersion')).match(/(.+)-\d.+/), '1'); - }.property('currentStackVersion'), + }.property('currentStackVersion', 'defaultStackVersion'), allHostNames: [], currentStackVersionNumber: function () { var regExp = new RegExp(this.get('currentStackName') + '-'); return (this.get('currentStackVersion') || this.get('defaultStackVersion')).replace(regExp, ''); - }.property('currentStackVersion', 'currentStackName'), + }.property('currentStackVersion', 'defaultStackVersion', 'currentStackName'), isHadoop2Stack: function () { var result = true; @@ -96,6 +96,10 @@ module.exports = Em.Application.create({ return (stringUtils.compareVersions(this.get('currentStackVersionNumber'), "2.2") > -1); }.property('currentStackVersionNumber'), + isHadoopWindowsStack: function() { + return this.get('currentStackName') == "HDPWIN"; + }.property('currentStackName'), + /** * If NameNode High Availability is enabled * Based on <code>clusterStatus.isInstalled</code>, stack version, <code>SNameNode</code> availability @@ -155,6 +159,18 @@ module.exports = Em.Application.create({ return App.StackService.find().filterProperty('isMonitoringService').mapProperty('serviceName'); }.property('App.router.clusterController.isLoaded'), + hostMetrics: function () { + return App.StackService.find().filterProperty('isHostMetricsService').mapProperty('serviceName'); + }.property('App.router.clusterController.isLoaded'), + + serviceMetrics: function () { + return App.StackService.find().filterProperty('isServiceMetricsService').mapProperty('serviceName'); + }.property('App.router.clusterController.isLoaded'), + + alerting: function () { + return App.StackService.find().filterProperty('isAlertingService').mapProperty('serviceName'); + }.property('App.router.clusterController.isLoaded'), + supportsServiceCheck: function() { return App.StackService.find().filterProperty('serviceCheckSupported').mapProperty('serviceName'); }.property('App.router.clusterController.isLoaded') |