You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by ak...@apache.org on 2015/08/17 16:13:54 UTC
ambari git commit: AMBARI-12787. Add Host is only performing Hostname
Resolution check for added hosts (akovalenko)
Repository: ambari
Updated Branches:
refs/heads/trunk baed7e987 -> 3299ce44e
AMBARI-12787. Add Host is only performing Hostname Resolution check for added hosts (akovalenko)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/3299ce44
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/3299ce44
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/3299ce44
Branch: refs/heads/trunk
Commit: 3299ce44ecc661a4dec678a50a730e4a162e88cc
Parents: baed7e9
Author: Aleksandr Kovalenko <ak...@hortonworks.com>
Authored: Mon Aug 17 15:40:49 2015 +0300
Committer: Aleksandr Kovalenko <ak...@hortonworks.com>
Committed: Mon Aug 17 17:13:29 2015 +0300
----------------------------------------------------------------------
.../app/controllers/wizard/step3_controller.js | 18 ++++++++++++++----
1 file changed, 14 insertions(+), 4 deletions(-)
----------------------------------------------------------------------
http://git-wip-us.apache.org/repos/asf/ambari/blob/3299ce44/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 e27abec..af4c7d3 100644
--- a/ambari-web/app/controllers/wizard/step3_controller.js
+++ b/ambari-web/app/controllers/wizard/step3_controller.js
@@ -81,6 +81,14 @@ App.WizardStep3Controller = Em.Controller.extend(App.ReloadPopupMixin, {
}.property('isRegistrationInProgress', 'isWarningsLoaded'),
/**
+ * Controller is using in Add Host Wizard
+ * @return {bool}
+ */
+ isAddHostWizard: function () {
+ return this.get('content.controllerName') === 'addHostController';
+ }.property('content.controllerName'),
+
+ /**
* @type {bool}
*/
isLoaded: false,
@@ -940,12 +948,14 @@ App.WizardStep3Controller = Em.Controller.extend(App.ReloadPopupMixin, {
* @param {string} checkExecuteList - for now supported:
* <code>"last_agent_env_check"<code>
* <code>"host_resolution_check"<code>
- * @param {boolean} addHosts - true
+ * @param {boolean} addHostsParameter - define whether add hosts parameter to RequestInfo
* @return {object|null}
* @method getDataForCheckRequest
*/
- getDataForCheckRequest: function (checkExecuteList, addHosts) {
- var hosts = this.get('bootHosts').filterProperty('bootStatus', 'REGISTERED').getEach('name').join(",");
+ getDataForCheckRequest: function (checkExecuteList, addHostsParameter) {
+ var newHosts = this.get('bootHosts').filterProperty('bootStatus', 'REGISTERED').getEach('name');
+ var hosts = this.get('isAddHostWizard') ? [].concat.apply([], App.MasterComponent.find().mapProperty('hostNames')).concat(newHosts).uniq() : newHosts;
+ hosts = hosts.join(',');
if (hosts.length == 0) return null;
var jdk_location = App.router.get('clusterController.ambariProperties.jdk_location');
var RequestInfo = {
@@ -957,7 +967,7 @@ App.WizardStep3Controller = Em.Controller.extend(App.ReloadPopupMixin, {
"threshold": "20"
}
};
- if (addHosts) {
+ if (addHostsParameter) {
RequestInfo.parameters.hosts = hosts;
}
var resource_filters = {