Repository: ambari Updated Branches: refs/heads/trunk 101c41a49 -> 211560943
AMBARI-7972 Remove "required value" for hive.zookeeper.quorum property in hive-site. (atkach) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/21156094 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/21156094 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/21156094 Branch: refs/heads/trunk Commit: 2115609432b40f19b448f551d2e485650cb0dfb9 Parents: 101c41a Author: atkach <[email protected]> Authored: Sun Oct 26 01:30:34 2014 +0300 Committer: atkach <[email protected]> Committed: Sun Oct 26 01:30:34 2014 +0300 ---------------------------------------------------------------------- ambari-web/app/controllers/main/service/add_controller.js | 4 +++- ambari-web/app/data/HDP2.2/site_properties.js | 1 + ambari-web/app/models/service_config.js | 6 ++++++ 3 files changed, 10 insertions(+), 1 deletion(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/21156094/ambari-web/app/controllers/main/service/add_controller.js ---------------------------------------------------------------------- diff --git a/ambari-web/app/controllers/main/service/add_controller.js b/ambari-web/app/controllers/main/service/add_controller.js index 44e8cf1..d2b1dd6 100644 --- a/ambari-web/app/controllers/main/service/add_controller.js +++ b/ambari-web/app/controllers/main/service/add_controller.js @@ -135,12 +135,14 @@ App.AddServiceController = App.WizardController.extend({ var installedComponents = App.HostComponent.find(); obj.forEach(function (_component) { + var installedComponent = installedComponents.findProperty('componentName', _component.component_name); masterComponentHosts.push({ display_name: _component.display_name, component: _component.component_name, hostName: _component.selectedHost, serviceId: _component.serviceId, - isInstalled: installedComponents.someProperty('componentName', _component.component_name) + isInstalled: !!installedComponent, + workStatus: installedComponent && installedComponent.get('workStatus') }); }); http://git-wip-us.apache.org/repos/asf/ambari/blob/21156094/ambari-web/app/data/HDP2.2/site_properties.js ---------------------------------------------------------------------- diff --git a/ambari-web/app/data/HDP2.2/site_properties.js b/ambari-web/app/data/HDP2.2/site_properties.js index a3f1d2c..f27d15d 100644 --- a/ambari-web/app/data/HDP2.2/site_properties.js +++ b/ambari-web/app/data/HDP2.2/site_properties.js @@ -43,6 +43,7 @@ hdp22properties.push( "displayName": "hive.zookeeper.quorum", "defaultValue": "localhost:2181", "displayType": "multiLine", + "isRequired": false, "isVisible": true, "serviceName": "HIVE", "category": "Advanced hive-site" http://git-wip-us.apache.org/repos/asf/ambari/blob/21156094/ambari-web/app/models/service_config.js ---------------------------------------------------------------------- diff --git a/ambari-web/app/models/service_config.js b/ambari-web/app/models/service_config.js index ae1c3ee..a21e0f8 100644 --- a/ambari-web/app/models/service_config.js +++ b/ambari-web/app/models/service_config.js @@ -498,6 +498,12 @@ App.ServiceConfigProperty = Ember.Object.extend({ case 'hadoop.registry.zk.quorum': case 'hive.cluster.delegation.token.store.zookeeper.connectString': var zkHosts = masterComponentHostsInDB.filterProperty('component', 'ZOOKEEPER_SERVER').mapProperty('hostName'); + if (this.get('name') === 'hive.zookeeper.quorum') { + zkHosts = masterComponentHostsInDB. + filterProperty('component', 'ZOOKEEPER_SERVER'). + filterProperty('workStatus', 'STARTED'). + mapProperty('hostName'); + } var zkHostPort = zkHosts; var regex = "\\w*:(\\d+)"; //regex to fetch the port var portValue = this.get('defaultValue').match(new RegExp(regex));
