You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@ambari.apache.org by dm...@apache.org on 2015/11/17 11:42:43 UTC

[2/2] ambari git commit: AMBARI-13909. RU: Flume restart failed during downgrade (dlysnichenko)

AMBARI-13909. RU: Flume restart failed during downgrade (dlysnichenko)


Project: http://git-wip-us.apache.org/repos/asf/ambari/repo
Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/f52dceb1
Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/f52dceb1
Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/f52dceb1

Branch: refs/heads/trunk
Commit: f52dceb1882754d71836877167dda61b209ddb03
Parents: ccdb155
Author: Lisnichenko Dmitro <dl...@hortonworks.com>
Authored: Tue Nov 17 12:39:26 2015 +0200
Committer: Lisnichenko Dmitro <dl...@hortonworks.com>
Committed: Tue Nov 17 12:42:12 2015 +0200

----------------------------------------------------------------------
 .../stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py        | 6 ++++++
 1 file changed, 6 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/f52dceb1/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py b/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py
index e1f33d4..5612d75 100644
--- a/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py
+++ b/ambari-server/src/main/resources/stacks/HDP/2.0.6/hooks/before-ANY/scripts/params.py
@@ -54,6 +54,12 @@ ambari_server_hostname = config['clusterHostInfo']['ambari_server_host'][0]
 stack_version_unformatted = str(config['hostLevelParams']['stack_version'])
 hdp_stack_version = format_hdp_stack_version(stack_version_unformatted)
 
+restart_type = default("/commandParams/restart_type", "")
+version = default("/commandParams/version", None)
+# Handle upgrade and downgrade
+if restart_type and version:
+  hdp_stack_version = format_hdp_stack_version(version)
+
 security_enabled = config['configurations']['cluster-env']['security_enabled']
 hdfs_user = config['configurations']['hadoop-env']['hdfs_user']