Repository: ambari Updated Branches: refs/heads/trunk 329d2b542 -> e6725016f
AMBARI-13308. Config Versions list isn't updated while user is on the configs page after adding/removing HiveServer2 (onechiporenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/e6725016 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/e6725016 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/e6725016 Branch: refs/heads/trunk Commit: e6725016f7417b6e90c1d3cde028a33bda41bf23 Parents: 329d2b5 Author: Oleg Nechiporenko <onechipore...@apache.org> Authored: Tue Oct 6 10:57:55 2015 +0300 Committer: Oleg Nechiporenko <onechipore...@apache.org> Committed: Tue Oct 6 10:57:55 2015 +0300 ---------------------------------------------------------------------- ambari-web/app/controllers/main/host/details.js | 19 +++++++++++++------ ambari-web/app/controllers/main/service/item.js | 2 +- 2 files changed, 14 insertions(+), 7 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/e6725016/ambari-web/app/controllers/main/host/details.js ---------------------------------------------------------------------- diff --git a/ambari-web/app/controllers/main/host/details.js b/ambari-web/app/controllers/main/host/details.js index 507e375..6c2f0e7 100644 --- a/ambari-web/app/controllers/main/host/details.js +++ b/ambari-web/app/controllers/main/host/details.js @@ -436,6 +436,9 @@ App.MainHostDetailsController = Em.Controller.extend(App.SupportClientConfigsDow } else if (data.componentName == 'HIVE_METASTORE') { this.set('deleteHiveMetaStore', true); this.loadConfigs('loadHiveConfigs'); + } else if (data.componentName == 'HIVE_SERVER') { + this.set('deleteHiveServer', true); + this.loadConfigs('loadHiveConfigs'); } else if (data.componentName == 'NIMBUS') { this.set('deleteNimbusHost', true); this.loadConfigs('loadStormConfigs'); @@ -671,7 +674,7 @@ App.MainHostDetailsController = Em.Controller.extend(App.SupportClientConfigsDow * @param {object} data * @param {object} opt * @param {object} params - * @method installNewComponentSuccessCallbƒack + * @method installNewComponentSuccessCallback */ installNewComponentSuccessCallback: function (data, opt, params) { if (!data || !data.Requests || !data.Requests.id) { @@ -824,13 +827,16 @@ App.MainHostDetailsController = Em.Controller.extend(App.SupportClientConfigsDow * @method loadHiveConfigs */ loadHiveConfigs: function (data) { - App.ajax.send({ + return App.ajax.send({ name: 'admin.get.all_configurations', sender: this, data: { - urlParams: '(type=hive-site&tag=' + data.Clusters.desired_configs['hive-site'].tag + ')|(type=webhcat-site&tag=' + - data.Clusters.desired_configs['webhcat-site'].tag + ')|(type=hive-env&tag=' + data.Clusters.desired_configs['hive-env'].tag + - ')|(type=core-site&tag=' + data.Clusters.desired_configs['core-site'].tag + ')' + urlParams: [ + '(type=hive-site&tag=' + data.Clusters.desired_configs['hive-site'].tag + ')', + '(type=webhcat-site&tag=' + data.Clusters.desired_configs['webhcat-site'].tag + ')', + '(type=hive-env&tag=' + data.Clusters.desired_configs['hive-env'].tag + ')', + '(type=core-site&tag=' + data.Clusters.desired_configs['core-site'].tag + ')' + ].join('|') }, success: 'onLoadHiveConfigs' }); @@ -965,8 +971,9 @@ App.MainHostDetailsController = Em.Controller.extend(App.SupportClientConfigsDow this.set('hiveMetastoreHost', ''); } - if (this.get('fromDeleteHost') || this.get('deleteHiveMetaStore')) { + if (this.get('fromDeleteHost') || this.get('deleteHiveMetaStore') || this.get('deleteHiveServer')) { this.set('deleteHiveMetaStore', false); + this.set('deleteHiveServer', false); this.set('fromDeleteHost', false); return hiveHosts.without(this.get('content.hostName')); } http://git-wip-us.apache.org/repos/asf/ambari/blob/e6725016/ambari-web/app/controllers/main/service/item.js ---------------------------------------------------------------------- diff --git a/ambari-web/app/controllers/main/service/item.js b/ambari-web/app/controllers/main/service/item.js index bd5bcc7..223e610 100644 --- a/ambari-web/app/controllers/main/service/item.js +++ b/ambari-web/app/controllers/main/service/item.js @@ -800,7 +800,7 @@ App.MainServiceItemController = Em.Controller.extend(App.SupportClientConfigsDow // Install if(['HIVE_METASTORE', 'RANGER_KMS_SERVER', 'NIMBUS'].contains(component.get('componentName')) && !!selectedHost){ - App.router.get('mainHostDetailsController').addComponent( + App.router.get('mainHostDetailsController').addComponentWithCheck( { context: component, selectedHost: selectedHost