You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ab...@apache.org on 2014/04/14 14:05:19 UTC
git commit: AMBARI-5457 Host Checks: alternatives check results are
not surfaced in Host Check popup. (ababiichuk)
Repository: ambari
Updated Branches:
refs/heads/trunk c9e181d25 -> 7db13dd36
AMBARI-5457 Host Checks: alternatives check results are not surfaced in Host Check popup. (ababiichuk)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/7db13dd3
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/7db13dd3
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/7db13dd3
Branch: refs/heads/trunk
Commit: 7db13dd368e57cd5bae69015cc1b4fbac70d41c6
Parents: c9e181d
Author: aBabiichuk <ab...@cybervisiontech.com>
Authored: Mon Apr 14 14:58:13 2014 +0300
Committer: aBabiichuk <ab...@cybervisiontech.com>
Committed: Mon Apr 14 15:00:32 2014 +0300
----------------------------------------------------------------------
.../app/controllers/wizard/step3_controller.js | 32 +++++++++++++++++++-
ambari-web/app/messages.js | 5 +++
.../wizard/step3_host_warnings_popup.hbs | 3 ++
3 files changed, 39 insertions(+), 1 deletion(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/7db13dd3/ambari-web/app/controllers/wizard/step3_controller.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/controllers/wizard/step3_controller.js b/ambari-web/app/controllers/wizard/step3_controller.js
index fb0a6f8..fa83375 100644
--- a/ambari-web/app/controllers/wizard/step3_controller.js
+++ b/ambari-web/app/controllers/wizard/step3_controller.js
@@ -764,7 +764,8 @@ App.WizardStep3Controller = Em.Controller.extend({
packagesWarnings: {},
processesWarnings: {},
servicesWarnings: {},
- usersWarnings: {}
+ usersWarnings: {},
+ alternativeWarnings: {}
};
data.items.sortPropertyLight('Hosts.host_name').forEach(function (_host) {
@@ -925,6 +926,25 @@ App.WizardStep3Controller = Em.Controller.extend({
host.warnings.push(warning);
}
+ if (_host.Hosts.last_agent_env.alternatives) {
+ _host.Hosts.last_agent_env.alternatives.forEach(function (alternative) {
+ warning = warningCategories.alternativeWarnings[alternative.name];
+ if (warning) {
+ warning.hosts.push(_host.Hosts.host_name);
+ warning.onSingleHost = false;
+ } else {
+ warningCategories.alternativeWarnings[alternative.name] = warning = {
+ name: alternative.name,
+ target: alternative.target,
+ hosts: [_host.Hosts.host_name],
+ category: 'alternatives',
+ onSingleHost: false
+ };
+ }
+ host.warnings.push(warning);
+ }, this);
+ }
+
hosts.push(host);
}, this);
@@ -1170,6 +1190,16 @@ App.WizardStep3Controller = Em.Controller.extend({
action: Em.I18n.t('installer.step3.hostWarningsPopup.action.exists'),
category: 'misc',
isCollapsed: true
+ }),
+ Ember.Object.create({
+ warnings: categoryWarnings.filterProperty('category', 'alternatives'),
+ title: Em.I18n.t('installer.step3.hostWarningsPopup.alternatives'),
+ message: Em.I18n.t('installer.step3.hostWarningsPopup.alternatives.message'),
+ type: Em.I18n.t('installer.step3.hostWarningsPopup.alternatives.umask'),
+ emptyName: Em.I18n.t('installer.step3.hostWarningsPopup.alternatives.emptyinstaller.step3.hostWarningsPopup.alternatives.empty'),
+ action: Em.I18n.t('installer.step3.hostWarningsPopup.action.exists'),
+ category: 'alternatives',
+ isCollapsed: true
})
]
}.property('category', 'warningsByHost'),
http://git-wip-us.apache.org/repos/asf/ambari/blob/7db13dd3/ambari-web/app/messages.js
----------------------------------------------------------------------
diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js
index d4ed91f..3d9dc96 100644
--- a/ambari-web/app/messages.js
+++ b/ambari-web/app/messages.js
@@ -483,6 +483,11 @@ Em.I18n.translations = {
'installer.step3.hostWarningsPopup.misc':'Misc Issues',
'installer.step3.hostWarningsPopup.misc.message':'The following umasks should be changed',
'installer.step3.hostWarningsPopup.misc.umask':'Umask',
+ 'installer.step3.hostWarningsPopup.alternatives':'Alternatives Issues',
+ 'installer.step3.hostWarningsPopup.alternatives.umask' : 'Alternatives',
+ 'installer.step3.hostWarningsPopup.alternatives.message':'The following alternatives should be removed',
+ 'installer.step3.hostWarningsPopup.alternatives.noIssues':'There was no alternative issue following alternatives should be removed',
+ 'installer.step3.hostWarningsPopup.alternatives.empty': 'alternative issues',
'installer.step3.hostWarningsPopup.issue':'issue',
'installer.step3.hostWarningsPopup.issues':'issues',
'installer.step3.hostWarningsPopup.emptyMessage':'There were no',
http://git-wip-us.apache.org/repos/asf/ambari/blob/7db13dd3/ambari-web/app/templates/wizard/step3_host_warnings_popup.hbs
----------------------------------------------------------------------
diff --git a/ambari-web/app/templates/wizard/step3_host_warnings_popup.hbs b/ambari-web/app/templates/wizard/step3_host_warnings_popup.hbs
index f9329ad..d4fe22c 100644
--- a/ambari-web/app/templates/wizard/step3_host_warnings_popup.hbs
+++ b/ambari-web/app/templates/wizard/step3_host_warnings_popup.hbs
@@ -66,6 +66,9 @@
{{#if warning.version}}
<td class="package-version">{{warning.version}}</td>
{{/if}}
+ {{#if warning.target}}
+ <td class="package-version">{{warning.target}}</td>
+ {{/if}}
<td>{{category.action}}
<a href="javascript:void(null);" rel='HostsListTooltip' {{bindAttr data-original-title="warning.hostsList"}} {{action showHostsPopup warning.hosts}}>
{{warning.hosts.length}}