ambari-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From adorosz...@apache.org
Subject ambari git commit: AMBARI-21554. Regenerating keytabs fails in Stack Advisor after upgrading Ambari
Date Thu, 03 Aug 2017 21:06:57 GMT
Repository: ambari
Updated Branches:
  refs/heads/branch-2.5 b167d3b2f -> d72f32936


AMBARI-21554. Regenerating keytabs fails in Stack Advisor after upgrading Ambari


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

Branch: refs/heads/branch-2.5
Commit: d72f32936c502d6420f4e0623c2adab1b0646247
Parents: b167d3b
Author: Attila Doroszlai <adoroszlai@hortonworks.com>
Authored: Thu Aug 3 14:37:44 2017 +0200
Committer: Attila Doroszlai <adoroszlai@hortonworks.com>
Committed: Thu Aug 3 23:06:22 2017 +0200

----------------------------------------------------------------------
 ambari-server/src/main/resources/scripts/stack_advisor.py | 7 +++++++
 1 file changed, 7 insertions(+)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/ambari/blob/d72f3293/ambari-server/src/main/resources/scripts/stack_advisor.py
----------------------------------------------------------------------
diff --git a/ambari-server/src/main/resources/scripts/stack_advisor.py b/ambari-server/src/main/resources/scripts/stack_advisor.py
index 66ab248..8e314ff 100755
--- a/ambari-server/src/main/resources/scripts/stack_advisor.py
+++ b/ambari-server/src/main/resources/scripts/stack_advisor.py
@@ -42,6 +42,11 @@ STACK_ADVISOR_DEFAULT_IMPL_CLASS = 'DefaultStackAdvisor'
 STACK_ADVISOR_IMPL_PATH_TEMPLATE = os.path.join(SCRIPT_DIRECTORY, './../stacks/{0}/{1}/services/stack_advisor.py')
 STACK_ADVISOR_IMPL_CLASS_TEMPLATE = '{0}{1}StackAdvisor'
 
+# Stack advisor may have deeper inheritance than the stack,
+# eg. BigInsights 4.0 is top-level, but its stack advisor inherits from HDP 2.5.
+# The extra classes are defined in the following directory:
+STACK_ADVISOR_BASE_MODULES = os.path.join(SCRIPT_DIRECTORY, '../stacks/{0}/{1}/stack-advisor')
+
 ADVISOR_CONTEXT = "advisor_context"
 CALL_TYPE = "call_type"
 
@@ -139,6 +144,8 @@ def instantiateStackAdvisor(stackName, stackVersion, parentVersions):
   versions = [stackVersion]
   versions.extend(parentVersions)
 
+  sys.path.append(STACK_ADVISOR_BASE_MODULES.format(stackName, versions[-1]))
+
   for version in reversed(versions):
     try:
       path = STACK_ADVISOR_IMPL_PATH_TEMPLATE.format(stackName, version)


Mime
View raw message