ambari git commit: AMBARI-18569. Execute topology tasks in parallel by hosts. (Attila Doroszlai via stoader)
Repository: ambari Updated Branches: refs/heads/trunk 2ddd7a338 -> 5dea886ef AMBARI-18569. Execute topology tasks in parallel by hosts. (Attila Doroszlai via stoader) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/5dea886e Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/5dea886e Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/5dea886e Branch: refs/heads/trunk Commit: 5dea886efde58fb93033f705b5dd43b5ccd72ad6 Parents: 2ddd7a3 Author: Attila Doroszlai Authored: Fri Nov 11 12:22:04 2016 +0100 Committer: Toader, Sebastian Committed: Fri Nov 11 12:22:04 2016 +0100 -- .../server/configuration/Configuration.java | 37 ++- .../AmbariManagementControllerImpl.java | 20 .../internal/ComponentResourceProvider.java | 4 +- .../internal/HostComponentResourceProvider.java | 2 +- .../internal/ServiceResourceProvider.java | 4 +- .../ambari/server/orm/entities/StackEntity.java | 10 +++- .../server/topology/HostOfferResponse.java | 46 -- .../ambari/server/topology/HostRequest.java | 18 +++ .../ambari/server/topology/LogicalRequest.java | 13 +++--- .../ambari/server/topology/TopologyManager.java | 49 ++-- .../server/configuration/ConfigurationTest.java | 6 +-- 11 files changed, 143 insertions(+), 66 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/5dea886e/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java b/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java index 9d2243b..15f186b 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java @@ -1,4 +1,4 @@ -/** +/* * Licensed to the Apache Software Foundation (ASF) under one * or more contributor license agreements. See the NOTICE file * distributed with this work for additional information @@ -100,7 +100,6 @@ import com.google.gson.JsonPrimitive; import com.google.inject.Inject; import com.google.inject.Singleton; - /** * The {@link Configuration} class is used to read from the * {{ambari.properties}} file and manage/expose the configuration properties. @@ -2481,6 +2480,22 @@ public class Configuration { public static final ConfigurationProperty LOG4JMONITOR_DELAY = new ConfigurationProperty<>( "log4j.monitor.delay", TimeUnit.MINUTES.toMillis(5)); + /** + * Indicates whether parallel topology task creation is enabled for blueprint cluster provisioning. + * Defaults to false. + * @see #TOPOLOGY_TASK_PARALLEL_CREATION_THREAD_COUNT + */ + @Markdown(description = "Indicates whether parallel topology task creation is enabled") + public static final ConfigurationProperty TOPOLOGY_TASK_PARALLEL_CREATION_ENABLED = new ConfigurationProperty<>("topology.task.creation.parallel", Boolean.FALSE); + + /** + * The number of threads to use for parallel topology task creation in blueprint cluster provisioning if enabled. + * Defaults to 10. + * @see #TOPOLOGY_TASK_PARALLEL_CREATION_ENABLED + */ + @Markdown(description = "The number of threads to use for parallel topology task creation if enabled") + public static final ConfigurationProperty TOPOLOGY_TASK_PARALLEL_CREATION_THREAD_COUNT = new ConfigurationProperty<>("topology.task.creation.parallel.threads", 10); + private static final Logger LOG = LoggerFactory.getLogger( Configuration.class); @@ -5168,6 +5183,24 @@ public class Configuration { } /** + * @return the number of threads to use for parallel topology task creation if enabled + */ + public int getParallelTopologyTaskCreationThreadPoolSize() { +try { + return Integer.parseInt(getProperty(TOPOLOGY_TASK_PARALLEL_CREATION_THREAD_COUNT)); +} catch (NumberFormatException e) { + return TOPOLOGY_TASK_PARALLEL_CREATION_THREAD_COUNT.getDefaultValue(); +} + } + + /** + * @return true if parallel execution of task creation is enabled explicitly + */ + public boolean isParallelTopologyTaskCreationEnabled() { +return Boolean.parseBoolean(getProperty(TOPOLOGY_TASK_PARALLEL_CREATION_ENABLED)); + } + + /** * Generates a markdown table which includes: * * Property key name http://git-wip-us.apache.org/repos/asf/ambari/blob/5dea886e/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java -- diff --git a/ambari-server/src/main/java/o
ambari git commit: AMBARI-18569. Execute topology tasks in parallel by hosts. (Attila Doroszlai via stoader)
Repository: ambari Updated Branches: refs/heads/branch-2.5 1e2c44bb4 -> 5eb3bb432 AMBARI-18569. Execute topology tasks in parallel by hosts. (Attila Doroszlai via stoader) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/5eb3bb43 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/5eb3bb43 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/5eb3bb43 Branch: refs/heads/branch-2.5 Commit: 5eb3bb432bd9570861c3bdd93476a3a2d85e8b76 Parents: 1e2c44b Author: Attila Doroszlai Authored: Fri Nov 11 13:08:14 2016 +0100 Committer: Toader, Sebastian Committed: Fri Nov 11 13:08:14 2016 +0100 -- .../server/configuration/Configuration.java | 35 +- .../AmbariManagementControllerImpl.java | 20 .../internal/ComponentResourceProvider.java | 4 +- .../internal/HostComponentResourceProvider.java | 2 +- .../internal/ServiceResourceProvider.java | 4 +- .../ambari/server/orm/entities/StackEntity.java | 10 +++- .../server/topology/HostOfferResponse.java | 46 -- .../ambari/server/topology/HostRequest.java | 18 +++ .../ambari/server/topology/LogicalRequest.java | 13 +++--- .../ambari/server/topology/TopologyManager.java | 49 ++-- .../server/configuration/ConfigurationTest.java | 6 +-- 11 files changed, 142 insertions(+), 65 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/5eb3bb43/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java b/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java index 6cc4120..45e2ea3 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/configuration/Configuration.java @@ -100,7 +100,6 @@ import com.google.gson.JsonPrimitive; import com.google.inject.Inject; import com.google.inject.Singleton; - /** * The {@link Configuration} class is used to read from the * {{ambari.properties}} file and manage/expose the configuration properties. @@ -2416,6 +2415,22 @@ public class Configuration { public static final ConfigurationProperty LOG4JMONITOR_DELAY = new ConfigurationProperty<>( "log4j.monitor.delay", TimeUnit.MINUTES.toMillis(5)); + /** + * Indicates whether parallel topology task creation is enabled for blueprint cluster provisioning. + * Defaults to false. + * @see #TOPOLOGY_TASK_PARALLEL_CREATION_THREAD_COUNT + */ + @Markdown(description = "Indicates whether parallel topology task creation is enabled") + public static final ConfigurationProperty TOPOLOGY_TASK_PARALLEL_CREATION_ENABLED = new ConfigurationProperty<>("topology.task.creation.parallel", Boolean.FALSE); + + /** + * The number of threads to use for parallel topology task creation in blueprint cluster provisioning if enabled. + * Defaults to 10. + * @see #TOPOLOGY_TASK_PARALLEL_CREATION_ENABLED + */ + @Markdown(description = "The number of threads to use for parallel topology task creation if enabled") + public static final ConfigurationProperty TOPOLOGY_TASK_PARALLEL_CREATION_THREAD_COUNT = new ConfigurationProperty<>("topology.task.creation.parallel.threads", 10); + private static final Logger LOG = LoggerFactory.getLogger( Configuration.class); @@ -5013,6 +5028,24 @@ public class Configuration { } /** + * @return the number of threads to use for parallel topology task creation if enabled + */ + public int getParallelTopologyTaskCreationThreadPoolSize() { +try { + return Integer.parseInt(getProperty(TOPOLOGY_TASK_PARALLEL_CREATION_THREAD_COUNT)); +} catch (NumberFormatException e) { + return TOPOLOGY_TASK_PARALLEL_CREATION_THREAD_COUNT.getDefaultValue(); +} + } + + /** + * @return true if parallel execution of task creation is enabled explicitly + */ + public boolean isParallelTopologyTaskCreationEnabled() { +return Boolean.parseBoolean(getProperty(TOPOLOGY_TASK_PARALLEL_CREATION_ENABLED)); + } + + /** * Generates a markdown table which includes: * * Property key name http://git-wip-us.apache.org/repos/asf/ambari/blob/5eb3bb43/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java index 9c030a3..292021c 1006
[1/2] ambari git commit: AMBARI-18861. Remove redundant css (part 1) (onechiporenko)
Repository: ambari Updated Branches: refs/heads/trunk 5dea886ef -> 2d948db31 http://git-wip-us.apache.org/repos/asf/ambari/blob/2d948db3/ambari-web/app/templates/wizard/step2.hbs -- diff --git a/ambari-web/app/templates/wizard/step2.hbs b/ambari-web/app/templates/wizard/step2.hbs index 55ebd79..4912851 100644 --- a/ambari-web/app/templates/wizard/step2.hbs +++ b/ambari-web/app/templates/wizard/step2.hbs @@ -36,13 +36,14 @@ - + {{view Ember.TextArea id="host-names" class="form-control" valueBinding="content.installOptions.hostNames" rows="5" placeholder="host names"}} - {{#if hostsError}} - {{hostsError}} + +{{hostsError}} + {{/if}} @@ -77,66 +78,76 @@ {{view App.SshKeyFileUploader disabledBinding="view.sshKeyState"}} {{/if}} + + {{! ssh key }} - + {{view Ember.TextArea class="form-control" rows="3" id="sshKey" placeholder="ssh private key" disabledBinding="view.sshKeyState" valueBinding="content.installOptions.sshKey"}} - {{#if sshKeyError}} - {{sshKeyError}} + +{{sshKeyError}} + {{/if}} - - - {{t installer.step2.sshUser}} - + {{! ssh key end }} - - - - {{view view.textFieldView valueBinding="content.installOptions.sshUser" isEnabledBinding="content.installOptions.useSsh" classNames="form-control"}} - -{{#if sshUserError}} - {{sshUserError}} -{{/if}} - + {{! ssh user }} + + + +{{t installer.step2.sshUser}} + + + + {{view view.textFieldView valueBinding="content.installOptions.sshUser" isEnabledBinding="content.installOptions.useSsh" classNames="form-control pull-right"}} +{{#if sshUserError}} + +{{sshUserError}} + +{{/if}} - - -{{t installer.step2.sshPort}} - + {{! ssh user end }} - - - -{{view view.textFieldView valueBinding="content.installOptions.sshPort" isEnabledBinding="content.installOptions.useSsh" classNames="form-control"}} - - {{#if sshPortError}} - {{sshPortError}} - {{/if}} - - + {{! ssh port }} + + + +{{t installer.step2.sshPort}} + + + + {{view view.textFieldView valueBinding="content.installOptions.sshPort" isEnabledBinding="content.installOptions.useSsh" classNames="form-control"}} + + {{#if sshPortError}} + + {{sshPortError}} + + {{/if}} - {{#if App.supports.customizeAgentUserAccount}} - - -{{t installer.step2.agentUser}} - + {{! ssh port end }} - - - -{{view view.textFieldView valueBinding="content.installOptions.agentUser" isEnabledBinding="content.installOptions.useSsh" classNames="form-control"}} - - {{#if agentUserError}} -{{agentUserError}} - {{/if}} - + {{! ambari agent user }} + {{#if App.supports.customizeAgentUserAccount}} + + + + {{t installer.step2.agentUser}} + + + +{{view view.textFieldView valueBinding="content.installOptions.agentUser" isEnabledBinding="content.installOptions.useSsh" classNames="form-control"}} + {{#if agentUserError}} + +
[2/2] ambari git commit: AMBARI-18861. Remove redundant css (part 1) (onechiporenko)
AMBARI-18861. Remove redundant css (part 1) (onechiporenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/2d948db3 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/2d948db3 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/2d948db3 Branch: refs/heads/trunk Commit: 2d948db3195286d7ee9eb7fe610628c9993ed865 Parents: 5dea886 Author: Oleg Nechiporenko Authored: Fri Nov 11 13:50:24 2016 +0200 Committer: Oleg Nechiporenko Committed: Fri Nov 11 13:50:24 2016 +0200 -- ambari-web/app/controllers/application.js | 4 +- ambari-web/app/models/host_component.js | 2 +- ambari-web/app/styles/application.less | 937 +++ ambari-web/app/styles/common.less | 148 ++- ambari-web/app/styles/config_history_flow.less | 36 +- ambari-web/app/styles/stack_versions.less | 3 +- ambari-web/app/templates/application.hbs| 65 +- ambari-web/app/templates/common/about.hbs | 6 +- .../common/assign_master_components.hbs | 10 +- ambari-web/app/templates/login.hbs | 2 +- .../app/templates/main/alerts/configs.hbs | 50 +- .../main/alerts/definition_details.hbs | 66 +- .../app/templates/main/charts/heatmap.hbs | 10 +- .../templates/main/charts/heatmap_dropdown.hbs | 7 +- .../templates/main/dashboard/config_history.hbs | 2 +- ambari-web/app/templates/main/host/configs.hbs | 6 +- .../templates/main/host/delete_hosts_popup.hbs | 2 +- .../main/host/details/doDeleteHostPopup.hbs | 2 +- ambari-web/app/templates/main/host/summary.hbs | 81 +- .../main/service/all_services_actions.hbs | 2 - .../main/service/info/heatmap_dropdown.hbs | 7 +- .../wizard/step1_addLocalRepository.hbs | 2 +- ambari-web/app/templates/wizard/step2.hbs | 105 ++- ambari-web/app/templates/wizard/step3.hbs | 3 +- ambari-web/app/views/main/menu.js | 2 +- 25 files changed, 462 insertions(+), 1098 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/2d948db3/ambari-web/app/controllers/application.js -- diff --git a/ambari-web/app/controllers/application.js b/ambari-web/app/controllers/application.js index 4bd09c3..df0a8e8 100644 --- a/ambari-web/app/controllers/application.js +++ b/ambari-web/app/controllers/application.js @@ -93,14 +93,14 @@ App.ApplicationController = Em.Controller.extend(App.UserPref, { } if (upgradeHolding) { return { -cls: 'upgrade-in-holding', +cls: 'upgrade-holding', icon: 'glyphicon-pause', msg: Em.I18n.t('admin.stackVersions.version.' + typeSuffix + '.pause') } } if (upgradeSuspended) { return { -cls: 'upgrade-in-holding', +cls: 'upgrade-aborted', icon: 'glyphicon-pause', msg: Em.I18n.t('admin.stackVersions.version.' + typeSuffix + '.suspended') } http://git-wip-us.apache.org/repos/asf/ambari/blob/2d948db3/ambari-web/app/models/host_component.js -- diff --git a/ambari-web/app/models/host_component.js b/ambari-web/app/models/host_component.js index 76d1023..d408bfd 100644 --- a/ambari-web/app/models/host_component.js +++ b/ambari-web/app/models/host_component.js @@ -250,7 +250,7 @@ App.HostComponentStatus = { case this.disabled: return 'Disabled'; case this.init: -return 'Install Pending...'; +return 'Install Pending'; } return 'Unknown'; }, http://git-wip-us.apache.org/repos/asf/ambari/blob/2d948db3/ambari-web/app/styles/application.less -- diff --git a/ambari-web/app/styles/application.less b/ambari-web/app/styles/application.less index 9d7d949..3d2375e 100644 --- a/ambari-web/app/styles/application.less +++ b/ambari-web/app/styles/application.less @@ -21,6 +21,7 @@ body { overflow-y: scroll; + line-height: 1.3em; } html, body { @@ -46,20 +47,10 @@ body.modal-open { padding-right: 0 !important; } -.glyphicon-2x{font-size: 2em;} -.glyphicon-3x{font-size: 3em;} -.glyphicon-4x{font-size: 4em;} -.glyphicon-5x{font-size: 5em;} - -body.modal-open { - //fix bootstrap padding when modal opened - padding-right: 0 !important; -} - @-moz-document url-prefix() { -input[type="file"] { - line-height: 25px!important; -} + input[type="file"] { +line-height: 25px!important; + } } ul.typeahead.dropdown-menu { @@ -70,11 +61,6 @@ select.form-control { display: inline-block; } -// Override bootstrap class to ensure that popover content will fit to popover window -.popover-content { - word-break: break-wo
ambari git commit: AMBARI-18847. Issues after fast switching service page tabs (akovalenko)
Repository: ambari Updated Branches: refs/heads/trunk 2d948db31 -> 9e82fd10c AMBARI-18847. Issues after fast switching service page tabs (akovalenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/9e82fd10 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/9e82fd10 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/9e82fd10 Branch: refs/heads/trunk Commit: 9e82fd10ca2b1615e08520881ad45d3d01ec24e6 Parents: 2d948db Author: Aleksandr Kovalenko Authored: Fri Nov 11 15:28:56 2016 +0200 Committer: Aleksandr Kovalenko Committed: Fri Nov 11 15:28:56 2016 +0200 -- .../controllers/main/service/info/configs.js| 26 +++ .../app/controllers/wizard/step7_controller.js | 3 +- ambari-web/app/mappers/configs/themes_mapper.js | 4 +- ambari-web/app/mixins.js| 1 + .../app/mixins/common/track_request_mixin.js| 47 .../app/mixins/common/widgets/widget_mixin.js | 8 ++-- .../app/mixins/main/service/groups_mapping.js | 4 +- .../models/configs/objects/service_config.js| 1 + ambari-web/app/utils/blueprint.js | 4 +- ambari-web/app/utils/ember_reopen.js| 2 +- .../configs/config_category_container_view.js | 4 +- .../views/common/configs/config_history_flow.js | 2 +- .../test/controllers/wizard/step7_test.js | 13 ++ 13 files changed, 86 insertions(+), 33 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/9e82fd10/ambari-web/app/controllers/main/service/info/configs.js -- diff --git a/ambari-web/app/controllers/main/service/info/configs.js b/ambari-web/app/controllers/main/service/info/configs.js index 31ea248..946a1b9 100644 --- a/ambari-web/app/controllers/main/service/info/configs.js +++ b/ambari-web/app/controllers/main/service/info/configs.js @@ -21,7 +21,7 @@ var batchUtils = require('utils/batch_scheduled_requests'); App.MainServiceInfoConfigsController = Em.Controller.extend(App.AddSecurityConfigs, App.ConfigsLoader, App.ServerValidatorMixin, App.EnhancedConfigsMixin, App.ThemesMappingMixin, App.ConfigsSaverMixin, - App.ConfigsComparator, App.ComponentActionsByConfigs, { + App.ConfigsComparator, App.ComponentActionsByConfigs, App.TrackRequestMixin, { name: 'mainServiceInfoConfigsController', @@ -43,8 +43,6 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.AddSecurityConfi selectedConfigGroup: null, - requestsInProgress: [], - groupsStore: App.ServiceConfigGroup.find(), /** @@ -232,25 +230,11 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.AddSecurityConfi }, /** - * register request to view to track his progress - * @param {$.ajax} request - * @method trackRequest - */ - trackRequest: function (request) { -this.get('requestsInProgress').push(request); - }, - - /** * clear and set properties to default value * @method clearStep */ clearStep: function () { -this.get('requestsInProgress').forEach(function(r) { - if (r && r.readyState !== 4) { -r.abort(); - } -}); -this.get('requestsInProgress').clear(); +this.abortRequests(); App.set('componentToBeAdded', {}); App.set('componentToBeDeleted', {}); this.clearLoadInfo(); @@ -305,14 +289,14 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.AddSecurityConfi acc.push(i); return Array.prototype.concat.apply(acc, App.StackService.find(i).get('dependentServiceNames').toArray()).without(serviceName).uniq(); }, [])); -this.loadConfigTheme(serviceName).always(function () { +this.trackRequest(this.loadConfigTheme(serviceName).always(function () { if (self.get('preSelectedConfigVersion')) { self.loadPreSelectedConfigVersion(); } else { self.loadCurrentVersions(); } - self.loadServiceConfigVersions(); -}); + self.trackRequest(self.loadServiceConfigVersions()); +})); }, /** http://git-wip-us.apache.org/repos/asf/ambari/blob/9e82fd10/ambari-web/app/controllers/wizard/step7_controller.js -- diff --git a/ambari-web/app/controllers/wizard/step7_controller.js b/ambari-web/app/controllers/wizard/step7_controller.js index e466d4e..3d22fe9 100644 --- a/ambari-web/app/controllers/wizard/step7_controller.js +++ b/ambari-web/app/controllers/wizard/step7_controller.js @@ -42,7 +42,7 @@ var App = require('app'); * @property {?object[]} slaveComponentHosts */ -App.WizardStep7Controller = Em.Controller.extend(App.ServerValidatorMixin, App.EnhancedConfigsMixin, App.ToggleIsRequiredMixin, App.GroupsMappingMixin, { +App.WizardStep7Cont
ambari git commit: AMBARI-18847. Issues after fast switching service page tabs (akovalenko)
Repository: ambari Updated Branches: refs/heads/branch-2.5 5eb3bb432 -> 0fc586fb3 AMBARI-18847. Issues after fast switching service page tabs (akovalenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/0fc586fb Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/0fc586fb Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/0fc586fb Branch: refs/heads/branch-2.5 Commit: 0fc586fb3ac5007c70b6aab6a8a65af7807cd1ec Parents: 5eb3bb4 Author: Aleksandr Kovalenko Authored: Fri Nov 11 14:43:11 2016 +0200 Committer: Aleksandr Kovalenko Committed: Fri Nov 11 15:33:38 2016 +0200 -- .../controllers/main/service/info/configs.js| 26 +++ .../app/controllers/wizard/step7_controller.js | 3 +- ambari-web/app/mappers/configs/themes_mapper.js | 4 +- ambari-web/app/mixins.js| 1 + .../app/mixins/common/track_request_mixin.js| 47 .../app/mixins/common/widgets/widget_mixin.js | 8 ++-- .../app/mixins/main/service/groups_mapping.js | 4 +- .../models/configs/objects/service_config.js| 1 + ambari-web/app/utils/blueprint.js | 4 +- ambari-web/app/utils/ember_reopen.js| 2 +- .../test/controllers/wizard/step7_test.js | 13 ++ 11 files changed, 82 insertions(+), 31 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/0fc586fb/ambari-web/app/controllers/main/service/info/configs.js -- diff --git a/ambari-web/app/controllers/main/service/info/configs.js b/ambari-web/app/controllers/main/service/info/configs.js index 31ea248..946a1b9 100644 --- a/ambari-web/app/controllers/main/service/info/configs.js +++ b/ambari-web/app/controllers/main/service/info/configs.js @@ -21,7 +21,7 @@ var batchUtils = require('utils/batch_scheduled_requests'); App.MainServiceInfoConfigsController = Em.Controller.extend(App.AddSecurityConfigs, App.ConfigsLoader, App.ServerValidatorMixin, App.EnhancedConfigsMixin, App.ThemesMappingMixin, App.ConfigsSaverMixin, - App.ConfigsComparator, App.ComponentActionsByConfigs, { + App.ConfigsComparator, App.ComponentActionsByConfigs, App.TrackRequestMixin, { name: 'mainServiceInfoConfigsController', @@ -43,8 +43,6 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.AddSecurityConfi selectedConfigGroup: null, - requestsInProgress: [], - groupsStore: App.ServiceConfigGroup.find(), /** @@ -232,25 +230,11 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.AddSecurityConfi }, /** - * register request to view to track his progress - * @param {$.ajax} request - * @method trackRequest - */ - trackRequest: function (request) { -this.get('requestsInProgress').push(request); - }, - - /** * clear and set properties to default value * @method clearStep */ clearStep: function () { -this.get('requestsInProgress').forEach(function(r) { - if (r && r.readyState !== 4) { -r.abort(); - } -}); -this.get('requestsInProgress').clear(); +this.abortRequests(); App.set('componentToBeAdded', {}); App.set('componentToBeDeleted', {}); this.clearLoadInfo(); @@ -305,14 +289,14 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.AddSecurityConfi acc.push(i); return Array.prototype.concat.apply(acc, App.StackService.find(i).get('dependentServiceNames').toArray()).without(serviceName).uniq(); }, [])); -this.loadConfigTheme(serviceName).always(function () { +this.trackRequest(this.loadConfigTheme(serviceName).always(function () { if (self.get('preSelectedConfigVersion')) { self.loadPreSelectedConfigVersion(); } else { self.loadCurrentVersions(); } - self.loadServiceConfigVersions(); -}); + self.trackRequest(self.loadServiceConfigVersions()); +})); }, /** http://git-wip-us.apache.org/repos/asf/ambari/blob/0fc586fb/ambari-web/app/controllers/wizard/step7_controller.js -- diff --git a/ambari-web/app/controllers/wizard/step7_controller.js b/ambari-web/app/controllers/wizard/step7_controller.js index e466d4e..3d22fe9 100644 --- a/ambari-web/app/controllers/wizard/step7_controller.js +++ b/ambari-web/app/controllers/wizard/step7_controller.js @@ -42,7 +42,7 @@ var App = require('app'); * @property {?object[]} slaveComponentHosts */ -App.WizardStep7Controller = Em.Controller.extend(App.ServerValidatorMixin, App.EnhancedConfigsMixin, App.ToggleIsRequiredMixin, App.GroupsMappingMixin, { +App.WizardStep7Controller = Em.Controller.extend(App.ServerValidatorMixin, App.EnhancedConfigsMixin, App.ToggleIsRequiredM
ambari git commit: AMBARI-18838: Remove references to ganglias and nagios in Ambari agent source code (dili)
Repository: ambari Updated Branches: refs/heads/trunk 9e82fd10c -> bed231b96 AMBARI-18838: Remove references to ganglias and nagios in Ambari agent source code (dili) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/bed231b9 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/bed231b9 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/bed231b9 Branch: refs/heads/trunk Commit: bed231b9668ba7d71720ee3f4abae0a93f3a4991 Parents: 9e82fd1 Author: Di Li Authored: Fri Nov 11 11:08:13 2016 -0500 Committer: Di Li Committed: Fri Nov 11 11:08:13 2016 -0500 -- ambari-agent/conf/unix/ambari-agent.ini | 2 +- ambari-agent/conf/windows/ambari-agent.ini| 5 ++--- ambari-agent/src/main/python/ambari_agent/AmbariConfig.py | 4 3 files changed, 3 insertions(+), 8 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/bed231b9/ambari-agent/conf/unix/ambari-agent.ini -- diff --git a/ambari-agent/conf/unix/ambari-agent.ini b/ambari-agent/conf/unix/ambari-agent.ini index 9a0b537..b0b64c9 100644 --- a/ambari-agent/conf/unix/ambari-agent.ini +++ b/ambari-agent/conf/unix/ambari-agent.ini @@ -50,7 +50,7 @@ pidLookupPath=/var/run/ [heartbeat] state_interval_seconds=60 dirs=/etc/hadoop,/etc/hadoop/conf,/etc/hbase,/etc/hcatalog,/etc/hive,/etc/oozie, - /etc/sqoop,/etc/ganglia, + /etc/sqoop, /var/run/hadoop,/var/run/zookeeper,/var/run/hbase,/var/run/templeton,/var/run/oozie, /var/log/hadoop,/var/log/zookeeper,/var/log/hbase,/var/run/templeton,/var/log/hive ; 0 - unlimited http://git-wip-us.apache.org/repos/asf/ambari/blob/bed231b9/ambari-agent/conf/windows/ambari-agent.ini -- diff --git a/ambari-agent/conf/windows/ambari-agent.ini b/ambari-agent/conf/windows/ambari-agent.ini index b7a0a4d..3612414 100644 --- a/ambari-agent/conf/windows/ambari-agent.ini +++ b/ambari-agent/conf/windows/ambari-agent.ini @@ -44,12 +44,11 @@ pidLookupPath=\\var\\run\\ambari-agent [heartbeat] state_interval_seconds=60 dirs=/etc/hadoop,/etc/hadoop/conf,/etc/hbase,/etc/hcatalog,/etc/hive,/etc/oozie, - /etc/sqoop,/etc/ganglia,/etc/nagios, + /etc/sqoop, /var/run/hadoop,/var/run/zookeeper,/var/run/hbase,/var/run/templeton,/var/run/oozie, /var/log/hadoop,/var/log/zookeeper,/var/log/hbase,/var/run/templeton,/var/log/hive, /var/log/nagios -rpms=nagios,ganglia, - hadoop,hadoop-lzo,hbase,oozie,sqoop,pig,zookeeper,hive,libconfuse,ambari-log4j +rpms=hadoop,hadoop-lzo,hbase,oozie,sqoop,pig,zookeeper,hive,libconfuse,ambari-log4j ; 0 - unlimited log_lines_count=300 idle_interval_min=1 http://git-wip-us.apache.org/repos/asf/ambari/blob/bed231b9/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py -- diff --git a/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py b/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py index 6e4d74a..a097f37 100644 --- a/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py +++ b/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py @@ -88,8 +88,6 @@ servicesToPidNames = { 'ZOOKEEPER_SERVER': 'zookeeper_server.pid', 'FLUME_SERVER': 'flume-node.pid', 'TEMPLETON_SERVER': 'templeton.pid', - 'GANGLIA_SERVER': 'gmetad.pid', - 'GANGLIA_MONITOR': 'gmond.pid', 'HBASE_MASTER': 'hbase-{USER}-master.pid', 'HBASE_REGIONSERVER': 'hbase-{USER}-regionserver.pid', 'HCATALOG_SERVER': 'webhcat.pid', @@ -125,8 +123,6 @@ pidPathVars = [ 'defaultValue' : '/var/run/hadoop'}, {'var' : 'hadoop_pid_dir_prefix', 'defaultValue' : '/var/run/hadoop'}, - {'var' : 'ganglia_runtime_dir', - 'defaultValue' : '/var/run/ganglia/hdp'}, {'var' : 'hbase_pid_dir', 'defaultValue' : '/var/run/hbase'}, {'var' : 'zk_pid_dir',
ambari git commit: AMBARI-18838: Remove references to ganglias and nagios in Ambari agent source code (dili)
Repository: ambari Updated Branches: refs/heads/branch-2.5 0fc586fb3 -> 329dcd09b AMBARI-18838: Remove references to ganglias and nagios in Ambari agent source code (dili) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/329dcd09 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/329dcd09 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/329dcd09 Branch: refs/heads/branch-2.5 Commit: 329dcd09bbd37407575ca492e7b6ec9d1cf42829 Parents: 0fc586f Author: Di Li Authored: Fri Nov 11 11:08:13 2016 -0500 Committer: Di Li Committed: Fri Nov 11 11:30:16 2016 -0500 -- ambari-agent/conf/unix/ambari-agent.ini | 2 +- ambari-agent/conf/windows/ambari-agent.ini| 5 ++--- ambari-agent/src/main/python/ambari_agent/AmbariConfig.py | 4 3 files changed, 3 insertions(+), 8 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/329dcd09/ambari-agent/conf/unix/ambari-agent.ini -- diff --git a/ambari-agent/conf/unix/ambari-agent.ini b/ambari-agent/conf/unix/ambari-agent.ini index 914e09a..0f89106 100644 --- a/ambari-agent/conf/unix/ambari-agent.ini +++ b/ambari-agent/conf/unix/ambari-agent.ini @@ -49,7 +49,7 @@ pidLookupPath=/var/run/ [heartbeat] state_interval_seconds=60 dirs=/etc/hadoop,/etc/hadoop/conf,/etc/hbase,/etc/hcatalog,/etc/hive,/etc/oozie, - /etc/sqoop,/etc/ganglia, + /etc/sqoop, /var/run/hadoop,/var/run/zookeeper,/var/run/hbase,/var/run/templeton,/var/run/oozie, /var/log/hadoop,/var/log/zookeeper,/var/log/hbase,/var/run/templeton,/var/log/hive ; 0 - unlimited http://git-wip-us.apache.org/repos/asf/ambari/blob/329dcd09/ambari-agent/conf/windows/ambari-agent.ini -- diff --git a/ambari-agent/conf/windows/ambari-agent.ini b/ambari-agent/conf/windows/ambari-agent.ini index b7a0a4d..3612414 100644 --- a/ambari-agent/conf/windows/ambari-agent.ini +++ b/ambari-agent/conf/windows/ambari-agent.ini @@ -44,12 +44,11 @@ pidLookupPath=\\var\\run\\ambari-agent [heartbeat] state_interval_seconds=60 dirs=/etc/hadoop,/etc/hadoop/conf,/etc/hbase,/etc/hcatalog,/etc/hive,/etc/oozie, - /etc/sqoop,/etc/ganglia,/etc/nagios, + /etc/sqoop, /var/run/hadoop,/var/run/zookeeper,/var/run/hbase,/var/run/templeton,/var/run/oozie, /var/log/hadoop,/var/log/zookeeper,/var/log/hbase,/var/run/templeton,/var/log/hive, /var/log/nagios -rpms=nagios,ganglia, - hadoop,hadoop-lzo,hbase,oozie,sqoop,pig,zookeeper,hive,libconfuse,ambari-log4j +rpms=hadoop,hadoop-lzo,hbase,oozie,sqoop,pig,zookeeper,hive,libconfuse,ambari-log4j ; 0 - unlimited log_lines_count=300 idle_interval_min=1 http://git-wip-us.apache.org/repos/asf/ambari/blob/329dcd09/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py -- diff --git a/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py b/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py index 1f8449e..c3d6c39 100644 --- a/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py +++ b/ambari-agent/src/main/python/ambari_agent/AmbariConfig.py @@ -88,8 +88,6 @@ servicesToPidNames = { 'ZOOKEEPER_SERVER': 'zookeeper_server.pid', 'FLUME_SERVER': 'flume-node.pid', 'TEMPLETON_SERVER': 'templeton.pid', - 'GANGLIA_SERVER': 'gmetad.pid', - 'GANGLIA_MONITOR': 'gmond.pid', 'HBASE_MASTER': 'hbase-{USER}-master.pid', 'HBASE_REGIONSERVER': 'hbase-{USER}-regionserver.pid', 'HCATALOG_SERVER': 'webhcat.pid', @@ -125,8 +123,6 @@ pidPathVars = [ 'defaultValue' : '/var/run/hadoop'}, {'var' : 'hadoop_pid_dir_prefix', 'defaultValue' : '/var/run/hadoop'}, - {'var' : 'ganglia_runtime_dir', - 'defaultValue' : '/var/run/ganglia/hdp'}, {'var' : 'hbase_pid_dir', 'defaultValue' : '/var/run/hbase'}, {'var' : 'zk_pid_dir',
ambari git commit: AMBARI-17041. Support password type for custom properties (alexantonenko)
Repository: ambari Updated Branches: refs/heads/branch-2.5 329dcd09b -> 3b4a7709d AMBARI-17041. Support password type for custom properties (alexantonenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/3b4a7709 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/3b4a7709 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/3b4a7709 Branch: refs/heads/branch-2.5 Commit: 3b4a7709dbe6eae3d5c8c0d025bb341dabe952be Parents: 329dcd0 Author: Alex Antonenko Authored: Fri Nov 11 19:48:18 2016 +0200 Committer: Alex Antonenko Committed: Fri Nov 11 19:48:18 2016 +0200 -- .../AmbariManagementControllerImpl.java | 33 +++ .../controller/ConfigurationResponse.java | 2 + .../ambari/server/utils/SecretReference.java| 23 +++ ambari-web/app/messages.js | 1 + .../app/mixins/common/configs/configs_saver.js | 9 +++- .../configs/objects/service_config_property.js | 7 .../common/configs/addPropertyWindow.hbs| 12 ++ ambari-web/app/utils/config.js | 27 ++-- .../configs/service_configs_by_category_view.js | 5 +++ .../mixins/common/configs/configs_saver_test.js | 43 ++-- 10 files changed, 147 insertions(+), 15 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/3b4a7709/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java index 292021c..5be87b5 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/AmbariManagementControllerImpl.java @@ -819,6 +819,25 @@ public class AmbariManagementControllerImpl implements AmbariManagementControlle Map requestProperties = request.getProperties(); +// Configuration attributes are optional. If not present, use default(provided by stack), otherwise merge default +// with request-provided +Map> requestPropertiesAttributes = request.getPropertiesAttributes(); + +if (requestPropertiesAttributes != null && requestPropertiesAttributes.containsKey(PASSWORD)) { + for (Map.Entry requestEntry : requestPropertiesAttributes.get(PASSWORD).entrySet()) { +String passwordProperty = requestEntry.getKey(); +if(requestProperties.containsKey(passwordProperty) && requestEntry.getValue().equals("true")) { + String passwordPropertyValue = requestProperties.get(passwordProperty); + if (!SecretReference.isSecret(passwordPropertyValue)) { +continue; + } + SecretReference ref = new SecretReference(passwordPropertyValue, cluster); + String refValue = ref.getValue(); + requestProperties.put(passwordProperty, refValue); +} + } +} + Map> propertiesTypes = cluster.getConfigPropertiesTypes(request.getType()); if(propertiesTypes.containsKey(PropertyType.PASSWORD)) { for(String passwordProperty : propertiesTypes.get(PropertyType.PASSWORD)) { @@ -842,10 +861,6 @@ public class AmbariManagementControllerImpl implements AmbariManagementControlle configs = new HashMap(); } -// Configuration attributes are optional. If not present, use default(provided by stack), otherwise merge default -// with request-provided -Map> requestPropertiesAttributes = request.getPropertiesAttributes(); - Map> propertiesAttributes = new HashMap>(); StackId currentStackId = cluster.getCurrentStackVersion(); @@ -1540,6 +1555,7 @@ public class AmbariManagementControllerImpl implements AmbariManagementControlle if (request.getDesiredConfig() != null) { for (ConfigurationRequest desiredConfig : request.getDesiredConfig()) { Map requestConfigProperties = desiredConfig.getProperties(); +Map> requestConfigAttributes = desiredConfig.getPropertiesAttributes(); // processing password properties if(requestConfigProperties != null && !requestConfigProperties.isEmpty()) { @@ -1549,8 +1565,11 @@ public class AmbariManagementControllerImpl implements AmbariManagementControlle for (Entry property : requestConfigProperties.entrySet()) { String propertyName = property.getKey(); String propertyValue = property.getValue(); -if (propertiesTypes.containsKey(PropertyType.PASSWORD) && - propertiesTypes.get(PropertyType.PASSWORD).contains(propert
[2/2] ambari git commit: AMBARI-18864. HDP 2.5 HDFS HA Cluster Installed From Blueprint Has ZKFC in UNKNOWN State (dlysnichenko)
AMBARI-18864. HDP 2.5 HDFS HA Cluster Installed From Blueprint Has ZKFC in UNKNOWN State (dlysnichenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/25847627 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/25847627 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/25847627 Branch: refs/heads/branch-2.5 Commit: 25847627da43eaa63bfc2f115fbab4c28af43396 Parents: 3b4a770 Author: Lisnichenko Dmitro Authored: Fri Nov 11 20:16:32 2016 +0200 Committer: Lisnichenko Dmitro Committed: Fri Nov 11 20:17:23 2016 +0200 -- .../common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/25847627/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py -- diff --git a/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py b/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py index ad8d65f..01ec1ff 100644 --- a/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py +++ b/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py @@ -43,7 +43,8 @@ from resource_management.libraries.functions.version_select_util import get_comp class ZkfcSlave(Script): def get_component_name(self): import params -if params.version and check_stack_feature(StackFeature.ZKFC_VERSION_ADVERTISED, params.version): +if params.version_for_stack_feature_checks and check_stack_feature(StackFeature.ZKFC_VERSION_ADVERTISED, params.version_for_stack_feature_checks): + # params.version is not defined when installing cluster from blueprint return "hadoop-hdfs-zkfc" pass
[1/2] ambari git commit: AMBARI-18864. HDP 2.5 HDFS HA Cluster Installed From Blueprint Has ZKFC in UNKNOWN State (dlysnichenko)
Repository: ambari Updated Branches: refs/heads/branch-2.5 3b4a7709d -> 25847627d refs/heads/trunk bed231b96 -> 1807a4aaa AMBARI-18864. HDP 2.5 HDFS HA Cluster Installed From Blueprint Has ZKFC in UNKNOWN State (dlysnichenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/1807a4aa Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/1807a4aa Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/1807a4aa Branch: refs/heads/trunk Commit: 1807a4aaa0f0cb9344fc0e624e4ced68e89a430f Parents: bed231b Author: Lisnichenko Dmitro Authored: Fri Nov 11 20:16:32 2016 +0200 Committer: Lisnichenko Dmitro Committed: Fri Nov 11 20:16:32 2016 +0200 -- .../common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/1807a4aa/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py -- diff --git a/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py b/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py index ddd1766..f1891a5 100644 --- a/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py +++ b/ambari-server/src/main/resources/common-services/HDFS/2.1.0.2.0/package/scripts/zkfc_slave.py @@ -43,7 +43,8 @@ from resource_management.libraries.functions.version_select_util import get_comp class ZkfcSlave(Script): def get_component_name(self): import params -if params.version and check_stack_feature(StackFeature.ZKFC_VERSION_ADVERTISED, params.version): +if params.version_for_stack_feature_checks and check_stack_feature(StackFeature.ZKFC_VERSION_ADVERTISED, params.version_for_stack_feature_checks): + # params.version is not defined when installing cluster from blueprint return "hadoop-hdfs-zkfc" pass
ambari git commit: AMBARI-18863 - Upgrade Type Is Incorrectly Quoted When Serialized (jonathanhurley)
Repository: ambari Updated Branches: refs/heads/trunk 1807a4aaa -> e569e9722 AMBARI-18863 - Upgrade Type Is Incorrectly Quoted When Serialized (jonathanhurley) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/e569e972 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/e569e972 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/e569e972 Branch: refs/heads/trunk Commit: e569e9722a89d3205a03c43efedbc6cfb7fecde7 Parents: 1807a4a Author: Jonathan Hurley Authored: Fri Nov 11 10:29:43 2016 -0500 Committer: Jonathan Hurley Committed: Fri Nov 11 13:27:03 2016 -0500 -- .../server/controller/internal/UpgradeResourceProvider.java | 8 ++-- .../controller/internal/UpgradeResourceProviderTest.java | 7 +-- 2 files changed, 11 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/e569e972/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java index 1713b64..1806c64 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java @@ -126,6 +126,7 @@ import com.google.common.collect.Lists; import com.google.common.collect.Sets; import com.google.gson.Gson; import com.google.gson.JsonArray; +import com.google.gson.JsonElement; import com.google.gson.JsonObject; import com.google.inject.Inject; import com.google.inject.Provider; @@ -1402,8 +1403,11 @@ public class UpgradeResourceProvider extends AbstractControllerResourceProvider Map commandParams = getNewParameterMap(request); if (null != context.getType()) { - // use the serialized attributes of the enum to convert it to a string - commandParams.put(COMMAND_PARAM_UPGRADE_TYPE, s_gson.toJson(context.getType())); + // use the serialized attributes of the enum to convert it to a string, + // but first we must convert it into an element so that we don't get a + // quoted string - using toString() actually returns a quoted stirng which is bad + JsonElement json = s_gson.toJsonTree(context.getType()); + commandParams.put(COMMAND_PARAM_UPGRADE_TYPE, json.getAsString()); } commandParams.put(COMMAND_PARAM_VERSION, context.getVersion()); http://git-wip-us.apache.org/repos/asf/ambari/blob/e569e972/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java -- diff --git a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java index 17e4f2d..14e3d08 100644 --- a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java +++ b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java @@ -1246,10 +1246,13 @@ public class UpgradeResourceProviderTest { List stageEntities = stageDAO.findByRequestId(entity.getRequestId()); Gson gson = new Gson(); for (StageEntity se : stageEntities) { - Map map = gson.> fromJson(se.getCommandParamsStage(), - Map.class); + Map map = gson.> fromJson(se.getCommandParamsStage(),Map.class); assertTrue(map.containsKey("upgrade_direction")); assertEquals("upgrade", map.get("upgrade_direction")); + + if(map.containsKey("upgrade_type")){ +assertEquals("rolling_upgrade", map.get("upgrade_type")); + } } List upgradeGroups = entity.getUpgradeGroups();
ambari git commit: AMBARI-18863 - Upgrade Type Is Incorrectly Quoted When Serialized (jonathanhurley)
Repository: ambari Updated Branches: refs/heads/branch-2.5 25847627d -> d6abb5ce8 AMBARI-18863 - Upgrade Type Is Incorrectly Quoted When Serialized (jonathanhurley) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/d6abb5ce Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/d6abb5ce Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/d6abb5ce Branch: refs/heads/branch-2.5 Commit: d6abb5ce84b837a0e4e0da95336cd0613a81d05c Parents: 2584762 Author: Jonathan Hurley Authored: Fri Nov 11 10:29:43 2016 -0500 Committer: Jonathan Hurley Committed: Fri Nov 11 13:27:29 2016 -0500 -- .../server/controller/internal/UpgradeResourceProvider.java | 8 ++-- .../controller/internal/UpgradeResourceProviderTest.java | 7 +-- 2 files changed, 11 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/d6abb5ce/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java index 840e1d4..2c65c51 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/controller/internal/UpgradeResourceProvider.java @@ -126,6 +126,7 @@ import com.google.common.collect.Lists; import com.google.common.collect.Sets; import com.google.gson.Gson; import com.google.gson.JsonArray; +import com.google.gson.JsonElement; import com.google.gson.JsonObject; import com.google.inject.Inject; import com.google.inject.Provider; @@ -1402,8 +1403,11 @@ public class UpgradeResourceProvider extends AbstractControllerResourceProvider Map commandParams = getNewParameterMap(request); if (null != context.getType()) { - // use the serialized attributes of the enum to convert it to a string - commandParams.put(COMMAND_PARAM_UPGRADE_TYPE, s_gson.toJson(context.getType())); + // use the serialized attributes of the enum to convert it to a string, + // but first we must convert it into an element so that we don't get a + // quoted string - using toString() actually returns a quoted stirng which is bad + JsonElement json = s_gson.toJsonTree(context.getType()); + commandParams.put(COMMAND_PARAM_UPGRADE_TYPE, json.getAsString()); } commandParams.put(COMMAND_PARAM_VERSION, context.getVersion()); http://git-wip-us.apache.org/repos/asf/ambari/blob/d6abb5ce/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java -- diff --git a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java index 30dd644..d69bdbe 100644 --- a/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java +++ b/ambari-server/src/test/java/org/apache/ambari/server/controller/internal/UpgradeResourceProviderTest.java @@ -1246,10 +1246,13 @@ public class UpgradeResourceProviderTest { List stageEntities = stageDAO.findByRequestId(entity.getRequestId()); Gson gson = new Gson(); for (StageEntity se : stageEntities) { - Map map = gson.> fromJson(se.getCommandParamsStage(), - Map.class); + Map map = gson.> fromJson(se.getCommandParamsStage(),Map.class); assertTrue(map.containsKey("upgrade_direction")); assertEquals("upgrade", map.get("upgrade_direction")); + + if(map.containsKey("upgrade_type")){ +assertEquals("rolling_upgrade", map.get("upgrade_type")); + } } List upgradeGroups = entity.getUpgradeGroups();
ambari git commit: Revert "AMBARI-18792. Update som configuration properties for hive interactive for the HDP 2.6 stack (sseth via Swapan Shridhar)"
Repository: ambari Updated Branches: refs/heads/trunk e569e9722 -> 057755eec Revert "AMBARI-18792. Update som configuration properties for hive interactive for the HDP 2.6 stack (sseth via Swapan Shridhar)" This reverts commit 03f6398fcfa7d2e8accd72013d834815ba8755c5. Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/057755ee Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/057755ee Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/057755ee Branch: refs/heads/trunk Commit: 057755eeca0e4271418fbc4c846432a3932ba2ee Parents: e569e97 Author: Swapan Shridhar Authored: Fri Nov 11 11:08:00 2016 -0800 Committer: Swapan Shridhar Committed: Fri Nov 11 11:08:00 2016 -0800 -- .../server/upgrade/UpgradeCatalog250.java | 67 +++- .../configuration/hive-interactive-site.xml | 57 - .../HIVE/configuration/tez-interactive-site.xml | 47 -- 3 files changed, 10 insertions(+), 161 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/057755ee/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java index e679ada..3425dd7 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java @@ -17,8 +17,13 @@ */ package org.apache.ambari.server.upgrade; -import com.google.inject.Inject; -import com.google.inject.Injector; +import java.sql.SQLException; +import java.util.ArrayList; +import java.util.Collections; +import java.util.HashMap; +import java.util.List; +import java.util.Map; + import org.apache.ambari.server.AmbariException; import org.apache.ambari.server.actionmanager.CommandExecutionType; import org.apache.ambari.server.controller.AmbariManagementController; @@ -32,13 +37,8 @@ import org.apache.commons.lang.StringUtils; import org.slf4j.Logger; import org.slf4j.LoggerFactory; -import java.sql.SQLException; -import java.util.ArrayList; -import java.util.Collections; -import java.util.HashMap; -import java.util.List; -import java.util.Map; -import java.util.Set; +import com.google.inject.Inject; +import com.google.inject.Injector; /** * Upgrade catalog for version 2.5.0. @@ -120,7 +120,7 @@ public class UpgradeCatalog250 extends AbstractUpgradeCatalog { */ @Override protected void executePreDMLUpdates() throws AmbariException, SQLException { -updateHiveLlapConfigs(); + } /** @@ -214,53 +214,6 @@ public class UpgradeCatalog250 extends AbstractUpgradeCatalog { } } - protected void updateHiveLlapConfigs() throws AmbariException { -AmbariManagementController ambariManagementController = injector.getInstance(AmbariManagementController.class); -Clusters clusters = ambariManagementController.getClusters(); - -if (clusters != null) { - Map clusterMap = clusters.getClusters(); - - if (clusterMap != null && !clusterMap.isEmpty()) { -for (final Cluster cluster : clusterMap.values()) { - Set installedServices = cluster.getServices().keySet(); - - if (installedServices.contains("HIVE")) { -Config hiveSite = cluster.getDesiredConfigByType("hive-interactive-site"); -if (hiveSite != null) { - Map hiveSiteProperties = hiveSite.getProperties(); - String schedulerDelay = hiveSiteProperties.get("hive.llap.task.scheduler.locality.delay"); - if (schedulerDelay != null) { -// Property exists. Change to new default if set to -1. -if (schedulerDelay.length() != 0) { - try { -int schedulerDelayInt = Integer.parseInt(schedulerDelay); -if (schedulerDelayInt == -1) { - // Old default. Set to new default. - updateConfigurationProperties("hive-interactive-site", Collections - .singletonMap("hive.llap.task.scheduler.locality.delay", "8000"), true, - false); -} - } catch (NumberFormatException e) { -// Invalid existing value. Set to new default. -updateConfigurationProperties("hive-interactive-site", Collections - .singletonMap("hive.llap.task.scheduler.locality.delay", "8000"), true, -false); - } -} - } - updateConfigurati
ambari git commit: Revert "AMBARI-18792. Update som configuration properties for hive interactive for the HDP 2.6 stack (sseth via Swapan Shridhar)"
Repository: ambari Updated Branches: refs/heads/branch-2.5 d6abb5ce8 -> 259269127 Revert "AMBARI-18792. Update som configuration properties for hive interactive for the HDP 2.6 stack (sseth via Swapan Shridhar)" This reverts commit 5ec99dccffb9b43b9a2373560548f990f74da00d. Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/25926912 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/25926912 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/25926912 Branch: refs/heads/branch-2.5 Commit: 259269127a3c452b2cbf2fcd093c6ac9f3a43fb9 Parents: d6abb5c Author: Swapan Shridhar Authored: Fri Nov 11 11:04:49 2016 -0800 Committer: Swapan Shridhar Committed: Fri Nov 11 11:04:49 2016 -0800 -- .../server/upgrade/UpgradeCatalog250.java | 50 + .../configuration/hive-interactive-site.xml | 57 .../HIVE/configuration/tez-interactive-site.xml | 47 3 files changed, 1 insertion(+), 153 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/25926912/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java index ee2ee8d..1e46e97 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/upgrade/UpgradeCatalog250.java @@ -23,7 +23,6 @@ import java.util.Collections; import java.util.HashMap; import java.util.List; import java.util.Map; -import java.util.Set; import org.apache.ambari.server.AmbariException; import org.apache.ambari.server.actionmanager.CommandExecutionType; @@ -121,7 +120,7 @@ public class UpgradeCatalog250 extends AbstractUpgradeCatalog { */ @Override protected void executePreDMLUpdates() throws AmbariException, SQLException { -updateHiveLlapConfigs(); + } /** @@ -190,53 +189,6 @@ public class UpgradeCatalog250 extends AbstractUpgradeCatalog { return content; } - protected void updateHiveLlapConfigs() throws AmbariException { -AmbariManagementController ambariManagementController = injector.getInstance(AmbariManagementController.class); -Clusters clusters = ambariManagementController.getClusters(); - -if (clusters != null) { - Map clusterMap = clusters.getClusters(); - - if (clusterMap != null && !clusterMap.isEmpty()) { -for (final Cluster cluster : clusterMap.values()) { - Set installedServices = cluster.getServices().keySet(); - - if (installedServices.contains("HIVE")) { -Config hiveSite = cluster.getDesiredConfigByType("hive-interactive-site"); -if (hiveSite != null) { - Map hiveSiteProperties = hiveSite.getProperties(); - String schedulerDelay = hiveSiteProperties.get("hive.llap.task.scheduler.locality.delay"); - if (schedulerDelay != null) { -// Property exists. Change to new default if set to -1. -if (schedulerDelay.length() != 0) { - try { -int schedulerDelayInt = Integer.parseInt(schedulerDelay); -if (schedulerDelayInt == -1) { - // Old default. Set to new default. - updateConfigurationProperties("hive-interactive-site", Collections - .singletonMap("hive.llap.task.scheduler.locality.delay", "8000"), true, - false); -} - } catch (NumberFormatException e) { -// Invalid existing value. Set to new default. -updateConfigurationProperties("hive-interactive-site", Collections - .singletonMap("hive.llap.task.scheduler.locality.delay", "8000"), true, -false); - } -} - } - updateConfigurationProperties("hive-interactive-site", - Collections.singletonMap("hive.mapjoin.hybridgrace.hashtable", "true"), true, - false); - // Explicitly skipping hive.llap.allow.permanent.fns during upgrades, since it's related to security, - // and we don't know if the value is set by the user or as a result of the previous default. -} - } -} - } -} - } - /** * Creates the servicecomponent_version table * @throws SQLException http://git-wip-us.apache.org/repos/asf/ambari/blob/25926912/ambari-server/src/main/resources/stacks
ambari git commit: Updated committer list. (yusaku)
Repository: ambari Updated Branches: refs/heads/trunk 057755eec -> fb584530d Updated committer list. (yusaku) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/fb584530 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/fb584530 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/fb584530 Branch: refs/heads/trunk Commit: fb584530dd97f3897accfb197d574dfb4f6864e8 Parents: 057755e Author: Yusaku Sako Authored: Fri Nov 11 11:27:48 2016 -0800 Committer: Yusaku Sako Committed: Fri Nov 11 11:27:48 2016 -0800 -- docs/pom.xml | 12 1 file changed, 12 insertions(+) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/fb584530/docs/pom.xml -- diff --git a/docs/pom.xml b/docs/pom.xml index 06bb72a..f1a 100644 --- a/docs/pom.xml +++ b/docs/pom.xml @@ -747,6 +747,18 @@ +rkamath +Renjith Kamath +rkam...@apache.org +-8 + +Committer + + +Hortonworks + + + rzang Richard Zang rz...@hortonworks.com
svn commit: r1769331 - in /ambari/site: issue-tracking.html license.html mail-lists.html project-info.html team-list.html
Author: yusaku Date: Fri Nov 11 19:28:16 2016 New Revision: 1769331 URL: http://svn.apache.org/viewvc?rev=1769331&view=rev Log: Updated committer list. (yusaku) Modified: ambari/site/issue-tracking.html ambari/site/license.html ambari/site/mail-lists.html ambari/site/project-info.html ambari/site/team-list.html Modified: ambari/site/issue-tracking.html URL: http://svn.apache.org/viewvc/ambari/site/issue-tracking.html?rev=1769331&r1=1769330&r2=1769331&view=diff == --- ambari/site/issue-tracking.html (original) +++ ambari/site/issue-tracking.html Fri Nov 11 19:28:16 2016 @@ -1,13 +1,13 @@ http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en"> - + Ambari - Issue Tracking @@ -329,7 +329,7 @@ - Last Published: 2016-11-06 | + Last Published: 2016-11-11 | Version: 2.4.1 Modified: ambari/site/license.html URL: http://svn.apache.org/viewvc/ambari/site/license.html?rev=1769331&r1=1769330&r2=1769331&view=diff == --- ambari/site/license.html (original) +++ ambari/site/license.html Fri Nov 11 19:28:16 2016 @@ -1,13 +1,13 @@ http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en"> - + Ambari - Project License @@ -329,7 +329,7 @@ - Last Published: 2016-11-06 | + Last Published: 2016-11-11 | Version: 2.4.1 Modified: ambari/site/mail-lists.html URL: http://svn.apache.org/viewvc/ambari/site/mail-lists.html?rev=1769331&r1=1769330&r2=1769331&view=diff == --- ambari/site/mail-lists.html (original) +++ ambari/site/mail-lists.html Fri Nov 11 19:28:16 2016 @@ -1,13 +1,13 @@ http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en"> - + Ambari - Project Mailing Lists @@ -329,7 +329,7 @@ - Last Published: 2016-11-06 | + Last Published: 2016-11-11 | Version: 2.4.1 Modified: ambari/site/project-info.html URL: http://svn.apache.org/viewvc/ambari/site/project-info.html?rev=1769331&r1=1769330&r2=1769331&view=diff == --- ambari/site/project-info.html (original) +++ ambari/site/project-info.html Fri Nov 11 19:28:16 2016 @@ -1,13 +1,13 @@ http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en"> - + Ambari - Project Information @@ -329,7 +329,7 @@ - Last Published: 2016-11-06 | + Last Published: 2016-11-11 | Version: 2.4.1 Modified: ambari/site/team-list.html URL: http://svn.apache.org/viewvc/ambari/site/team-list.html?rev=1769331&r1=1769330&r2=1769331&view=diff == --- ambari/site/team-list.html (original) +++ ambari/site/team-list.html Fri Nov 11 19:28:16 2016 @@ -1,13 +1,13 @@ http://www.w3.org/1999/xhtml"; xml:lang="en" lang="en"> - + Ambari - Team list @@ -329,7 +329,7 @@ - Last Published: 2016-11-06 | + Last Published: 2016-11-11 | Version: 2.4.1 @@ -1266,189 +1266,197 @@ -8 -8 +rkamath +Renjith Kamath +mailto:rkam...@apache.org";>rkam...@apache.org +Hortonworks +Committer +-8 +-8 + rzang Richard Zang mailto:rz...@hortonworks.com";>rz...@hortonworks.com Hortonworks Committer -8 --8 - +-8 + rlevas Robert Levas mailto:rle...@apache.org";>rle...@apache.org Hortonworks PMC -8 --8 - +-8 + rnettleton Bob Nettleton mailto:rnettle...@apache.org";>rnettle...@apache.org Hortonworks PMC -8 --8 - +-8 + sangeetar Sangeeta Ravindran mailto:sangee...@apache.org";>sangee...@apache.org IBM Committer -8 --8 - +-8 + screeley Scott Creeley mailto:scree...@apache.org";>scree...@apache.org Red Hat Committer -8 --8 - +-8 + smohanty Sumit Mohanty mailto:smoha...@apache.org";>smoha...@apache.org Hortonworks PMC -8 --8 - +-8 + smnaha Nahappan Somasundaram mailto:smn...@apache.org";>smn...@apache.org Hortonworks Committer -8 --8 - +-8 + sposetti Jeff Sposetti mailto:spose...@apache.org";>spose...@apache.org Hortonworks PMC -8 --8 - +-8 + stoader Sebastian Toader mailto:st
ambari git commit: AMBARI-18862. KAFKA broker start failed during restart stale config services after updating log directory.(vbrodetskyi)
Repository: ambari Updated Branches: refs/heads/trunk fb584530d -> e256cfe49 AMBARI-18862. KAFKA broker start failed during restart stale config services after updating log directory.(vbrodetskyi) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/e256cfe4 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/e256cfe4 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/e256cfe4 Branch: refs/heads/trunk Commit: e256cfe49ac171e96cf8e8c755dfa1938e10d97a Parents: fb58453 Author: Vitaly Brodetskyi Authored: Fri Nov 11 06:41:08 2016 +0200 Committer: Vitaly Brodetskyi Committed: Fri Nov 11 06:41:08 2016 +0200 -- .../KAFKA/0.8.1/package/scripts/kafka.py| 26 ++-- 1 file changed, 19 insertions(+), 7 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/e256cfe4/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py -- diff --git a/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py b/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py index 88d8a9b..a53a547 100644 --- a/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py +++ b/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py @@ -65,15 +65,15 @@ def kafka(upgrade_type=None): kafka_server_config['listeners'] = listeners.replace("6667", port) Logger.info(format("Kafka listeners after the port update: {listeners}")) del kafka_server_config['port'] - - + + if effective_version is not None and effective_version != "" and \ check_stack_feature(StackFeature.CREATE_KAFKA_BROKER_ID, effective_version): if len(params.kafka_hosts) > 0 and params.hostname in params.kafka_hosts: brokerid = str(sorted(params.kafka_hosts).index(params.hostname)) kafka_server_config['broker.id'] = brokerid Logger.info(format("Calculating broker.id as {brokerid}")) - + # listeners and advertised.listeners are only added in 2.3.0.0 onwards. if effective_version is not None and effective_version != "" and \ check_stack_feature(StackFeature.KAFKA_LISTENERS, effective_version): @@ -210,9 +210,15 @@ def setup_symlink(kafka_managed_dir, kafka_ambari_managed_dir): if backup_folder_path: # Restore backed up files to current relevant dirs if needed - will be triggered only when changing to/from default path; for file in os.listdir(backup_folder_path): - File(os.path.join(kafka_managed_dir,file), - owner=params.kafka_user, - content = StaticFile(os.path.join(backup_folder_path,file))) + if os.path.isdir(os.path.join(backup_folder_path, file)): +Execute(('cp', '-r', os.path.join(backup_folder_path, file), kafka_managed_dir), +sudo=True) +Execute(("chown", "-R", format("{kafka_user}:{user_group}"), os.path.join(kafka_managed_dir, file)), +sudo=True) + else: +File(os.path.join(kafka_managed_dir,file), + owner=params.kafka_user, + content = StaticFile(os.path.join(backup_folder_path,file))) # Clean up backed up folder Directory(backup_folder_path, @@ -234,7 +240,13 @@ def backup_dir_contents(dir_path, backup_folder_suffix): ) # Safely copy top-level contents to backup folder for file in os.listdir(dir_path): -File(os.path.join(backup_destination_path, file), +if os.path.isdir(os.path.join(dir_path, file)): + Execute(('cp', '-r', os.path.join(dir_path, file), backup_destination_path), + sudo=True) + Execute(("chown", "-R", format("{kafka_user}:{user_group}"), os.path.join(backup_destination_path, file)), + sudo=True) +else: + File(os.path.join(backup_destination_path, file), owner=params.kafka_user, content = StaticFile(os.path.join(dir_path,file)))
ambari git commit: AMBARI-18862. KAFKA broker start failed during restart stale config services after updating log directory.(vbrodetskyi)
Repository: ambari Updated Branches: refs/heads/branch-2.4 7116c0132 -> 494795607 AMBARI-18862. KAFKA broker start failed during restart stale config services after updating log directory.(vbrodetskyi) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/49479560 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/49479560 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/49479560 Branch: refs/heads/branch-2.4 Commit: 494795607c52a373db68099b472e5ede707d1794 Parents: 7116c01 Author: Vitaly Brodetskyi Authored: Fri Nov 11 06:48:43 2016 +0200 Committer: Vitaly Brodetskyi Committed: Fri Nov 11 06:48:43 2016 +0200 -- .../KAFKA/0.8.1/package/scripts/kafka.py| 26 ++-- 1 file changed, 19 insertions(+), 7 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/49479560/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py -- diff --git a/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py b/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py index ac7b0ae..6b4579c 100644 --- a/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py +++ b/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py @@ -65,15 +65,15 @@ def kafka(upgrade_type=None): kafka_server_config['listeners'] = listeners.replace("6667", port) Logger.info(format("Kafka listeners after the port update: {listeners}")) del kafka_server_config['port'] - - + + if effective_version is not None and effective_version != "" and \ check_stack_feature(StackFeature.CREATE_KAFKA_BROKER_ID, effective_version): if len(params.kafka_hosts) > 0 and params.hostname in params.kafka_hosts: brokerid = str(sorted(params.kafka_hosts).index(params.hostname)) kafka_server_config['broker.id'] = brokerid Logger.info(format("Calculating broker.id as {brokerid}")) - + # listeners and advertised.listeners are only added in 2.3.0.0 onwards. if effective_version is not None and effective_version != "" and \ check_stack_feature(StackFeature.KAFKA_LISTENERS, effective_version): @@ -215,9 +215,15 @@ def setup_symlink(kafka_managed_dir, kafka_ambari_managed_dir): if backup_folder_path: # Restore backed up files to current relevant dirs if needed - will be triggered only when changing to/from default path; for file in os.listdir(backup_folder_path): - File(os.path.join(kafka_managed_dir,file), - owner=params.kafka_user, - content = StaticFile(os.path.join(backup_folder_path,file))) + if os.path.isdir(os.path.join(backup_folder_path, file)): +Execute(('cp', '-r', os.path.join(backup_folder_path, file), kafka_managed_dir), +sudo=True) +Execute(("chown", "-R", format("{kafka_user}:{user_group}"), os.path.join(kafka_managed_dir, file)), +sudo=True) + else: +File(os.path.join(kafka_managed_dir,file), + owner=params.kafka_user, + content = StaticFile(os.path.join(backup_folder_path,file))) # Clean up backed up folder Directory(backup_folder_path, @@ -239,7 +245,13 @@ def backup_dir_contents(dir_path, backup_folder_suffix): ) # Safely copy top-level contents to backup folder for file in os.listdir(dir_path): -File(os.path.join(backup_destination_path, file), +if os.path.isdir(os.path.join(dir_path, file)): + Execute(('cp', '-r', os.path.join(dir_path, file), backup_destination_path), + sudo=True) + Execute(("chown", "-R", format("{kafka_user}:{user_group}"), os.path.join(backup_destination_path, file)), + sudo=True) +else: + File(os.path.join(backup_destination_path, file), owner=params.kafka_user, content = StaticFile(os.path.join(dir_path,file)))
ambari git commit: AMBARI-18862. KAFKA broker start failed during restart stale config services after updating log directory.(vbrodetskyi)
Repository: ambari Updated Branches: refs/heads/branch-2.5 259269127 -> 487f20a66 AMBARI-18862. KAFKA broker start failed during restart stale config services after updating log directory.(vbrodetskyi) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/487f20a6 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/487f20a6 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/487f20a6 Branch: refs/heads/branch-2.5 Commit: 487f20a660ced77cc1bd0f05ebf5d78ac4cfb530 Parents: 2592691 Author: Vitaly Brodetskyi Authored: Fri Nov 11 06:43:52 2016 +0200 Committer: Vitaly Brodetskyi Committed: Fri Nov 11 06:43:52 2016 +0200 -- .../KAFKA/0.8.1/package/scripts/kafka.py| 26 ++-- 1 file changed, 19 insertions(+), 7 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/487f20a6/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py -- diff --git a/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py b/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py index ac7b0ae..6b4579c 100644 --- a/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py +++ b/ambari-server/src/main/resources/common-services/KAFKA/0.8.1/package/scripts/kafka.py @@ -65,15 +65,15 @@ def kafka(upgrade_type=None): kafka_server_config['listeners'] = listeners.replace("6667", port) Logger.info(format("Kafka listeners after the port update: {listeners}")) del kafka_server_config['port'] - - + + if effective_version is not None and effective_version != "" and \ check_stack_feature(StackFeature.CREATE_KAFKA_BROKER_ID, effective_version): if len(params.kafka_hosts) > 0 and params.hostname in params.kafka_hosts: brokerid = str(sorted(params.kafka_hosts).index(params.hostname)) kafka_server_config['broker.id'] = brokerid Logger.info(format("Calculating broker.id as {brokerid}")) - + # listeners and advertised.listeners are only added in 2.3.0.0 onwards. if effective_version is not None and effective_version != "" and \ check_stack_feature(StackFeature.KAFKA_LISTENERS, effective_version): @@ -215,9 +215,15 @@ def setup_symlink(kafka_managed_dir, kafka_ambari_managed_dir): if backup_folder_path: # Restore backed up files to current relevant dirs if needed - will be triggered only when changing to/from default path; for file in os.listdir(backup_folder_path): - File(os.path.join(kafka_managed_dir,file), - owner=params.kafka_user, - content = StaticFile(os.path.join(backup_folder_path,file))) + if os.path.isdir(os.path.join(backup_folder_path, file)): +Execute(('cp', '-r', os.path.join(backup_folder_path, file), kafka_managed_dir), +sudo=True) +Execute(("chown", "-R", format("{kafka_user}:{user_group}"), os.path.join(kafka_managed_dir, file)), +sudo=True) + else: +File(os.path.join(kafka_managed_dir,file), + owner=params.kafka_user, + content = StaticFile(os.path.join(backup_folder_path,file))) # Clean up backed up folder Directory(backup_folder_path, @@ -239,7 +245,13 @@ def backup_dir_contents(dir_path, backup_folder_suffix): ) # Safely copy top-level contents to backup folder for file in os.listdir(dir_path): -File(os.path.join(backup_destination_path, file), +if os.path.isdir(os.path.join(dir_path, file)): + Execute(('cp', '-r', os.path.join(dir_path, file), backup_destination_path), + sudo=True) + Execute(("chown", "-R", format("{kafka_user}:{user_group}"), os.path.join(backup_destination_path, file)), + sudo=True) +else: + File(os.path.join(backup_destination_path, file), owner=params.kafka_user, content = StaticFile(os.path.join(dir_path,file)))
ambari git commit: AMBARI-18855 - Manage JournalNode Wizard: While assigning new JournalNodes, Current JournalNode selection value changes (rzang)
Repository: ambari Updated Branches: refs/heads/branch-2.5 487f20a66 -> 84972e3b8 AMBARI-18855 - Manage JournalNode Wizard: While assigning new JournalNodes, Current JournalNode selection value changes (rzang) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/84972e3b Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/84972e3b Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/84972e3b Branch: refs/heads/branch-2.5 Commit: 84972e3b898aac688deb2f625d0b084ae0f8f814 Parents: 487f20a Author: Richard Zang Authored: Fri Nov 11 15:56:26 2016 -0800 Committer: Richard Zang Committed: Fri Nov 11 15:56:26 2016 -0800 -- .../main/admin/highAvailability/journalNode/step1_controller.js | 5 - ambari-web/app/mixins/wizard/assign_master_components.js| 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/84972e3b/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js -- diff --git a/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js b/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js index c834517..b6ffe5b 100644 --- a/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js +++ b/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js @@ -34,6 +34,8 @@ App.ManageJournalNodeWizardStep1Controller = Em.Controller.extend(App.BlueprintM JOURNALNODES_COUNT_MINIMUM: 3, // TODO get this from stack + nextButtonCheckTrigger: true, + /** * On initial rendering, load equivalent number of existing JournalNodes to masterToShow * @param masterComponents @@ -50,6 +52,7 @@ App.ManageJournalNodeWizardStep1Controller = Em.Controller.extend(App.BlueprintM this._super(masterComponents); this.updateJournalNodeInfo(); this.showHideJournalNodesAddRemoveControl(); +this.toggleProperty('nextButtonCheckTrigger'); }, /** @@ -103,7 +106,7 @@ App.ManageJournalNodeWizardStep1Controller = Em.Controller.extend(App.BlueprintM var currentHosts = this.get('selectedServicesMasters').filterProperty('component_name', 'JOURNALNODE').mapProperty('selectedHost'); var originalHosts = App.HostComponent.find().filterProperty('componentName', 'JOURNALNODE').mapProperty('hostName'); return currentHosts.sort().join() == originalHosts.sort().join(); - }.property('hostNameCheckTrigger') + }.property('hostNameCheckTrigger', 'nextButtonCheckTrigger') }); http://git-wip-us.apache.org/repos/asf/ambari/blob/84972e3b/ambari-web/app/mixins/wizard/assign_master_components.js -- diff --git a/ambari-web/app/mixins/wizard/assign_master_components.js b/ambari-web/app/mixins/wizard/assign_master_components.js index 46409b2..d8ada11 100644 --- a/ambari-web/app/mixins/wizard/assign_master_components.js +++ b/ambari-web/app/mixins/wizard/assign_master_components.js @@ -1054,7 +1054,7 @@ App.AssignMasterComponents = Em.Mixin.create({ */ var maxNumMasters = this.getMaxNumberOfMasters(componentName), -currentMasters = this.get("selectedServicesMasters").filterProperty("component_name", componentName), +currentMasters = this.get("selectedServicesMasters").filterProperty("component_name", componentName).sortProperty('serviceComponentId'), newMaster = null, masterHosts = null, suggestedHost = null,
ambari git commit: AMBARI-18855 - Manage JournalNode Wizard: While assigning new JournalNodes, Current JournalNode selection value changes (rzang)
Repository: ambari Updated Branches: refs/heads/trunk e256cfe49 -> fa8f8405f AMBARI-18855 - Manage JournalNode Wizard: While assigning new JournalNodes, Current JournalNode selection value changes (rzang) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/fa8f8405 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/fa8f8405 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/fa8f8405 Branch: refs/heads/trunk Commit: fa8f8405fd746a978523572a667cebd4a284f20b Parents: e256cfe Author: Richard Zang Authored: Fri Nov 11 15:56:26 2016 -0800 Committer: Richard Zang Committed: Fri Nov 11 16:04:31 2016 -0800 -- .../main/admin/highAvailability/journalNode/step1_controller.js | 5 - ambari-web/app/mixins/wizard/assign_master_components.js| 2 +- 2 files changed, 5 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/fa8f8405/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js -- diff --git a/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js b/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js index c834517..b6ffe5b 100644 --- a/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js +++ b/ambari-web/app/controllers/main/admin/highAvailability/journalNode/step1_controller.js @@ -34,6 +34,8 @@ App.ManageJournalNodeWizardStep1Controller = Em.Controller.extend(App.BlueprintM JOURNALNODES_COUNT_MINIMUM: 3, // TODO get this from stack + nextButtonCheckTrigger: true, + /** * On initial rendering, load equivalent number of existing JournalNodes to masterToShow * @param masterComponents @@ -50,6 +52,7 @@ App.ManageJournalNodeWizardStep1Controller = Em.Controller.extend(App.BlueprintM this._super(masterComponents); this.updateJournalNodeInfo(); this.showHideJournalNodesAddRemoveControl(); +this.toggleProperty('nextButtonCheckTrigger'); }, /** @@ -103,7 +106,7 @@ App.ManageJournalNodeWizardStep1Controller = Em.Controller.extend(App.BlueprintM var currentHosts = this.get('selectedServicesMasters').filterProperty('component_name', 'JOURNALNODE').mapProperty('selectedHost'); var originalHosts = App.HostComponent.find().filterProperty('componentName', 'JOURNALNODE').mapProperty('hostName'); return currentHosts.sort().join() == originalHosts.sort().join(); - }.property('hostNameCheckTrigger') + }.property('hostNameCheckTrigger', 'nextButtonCheckTrigger') }); http://git-wip-us.apache.org/repos/asf/ambari/blob/fa8f8405/ambari-web/app/mixins/wizard/assign_master_components.js -- diff --git a/ambari-web/app/mixins/wizard/assign_master_components.js b/ambari-web/app/mixins/wizard/assign_master_components.js index 70f1638..7ef7fde 100644 --- a/ambari-web/app/mixins/wizard/assign_master_components.js +++ b/ambari-web/app/mixins/wizard/assign_master_components.js @@ -993,7 +993,7 @@ App.AssignMasterComponents = Em.Mixin.create(App.HostComponentValidationMixin, A */ var maxNumMasters = this.getMaxNumberOfMasters(componentName), -currentMasters = this.get("selectedServicesMasters").filterProperty("component_name", componentName), +currentMasters = this.get("selectedServicesMasters").filterProperty("component_name", componentName).sortProperty('serviceComponentId'), newMaster = null, masterHosts = null, suggestedHost = null,