AMBARI-22661 Storm service check fails with StormAtlasHook CNF after cluster deploy (dgrinenko)
Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/ab342d77 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/ab342d77 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/ab342d77 Branch: refs/heads/branch-feature-AMBARI-21674 Commit: ab342d77fab0baca7baabc23af8a6f86422c0642 Parents: 856d9a5 Author: Dmytro Grinenko <hapyles...@apache.org> Authored: Sat Dec 16 19:26:43 2017 +0200 Committer: Dmytro Grinenko <hapyles...@apache.org> Committed: Sat Dec 16 19:27:19 2017 +0200 ---------------------------------------------------------------------- .../libraries/functions/setup_atlas_hook.py | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/ambari/blob/ab342d77/ambari-common/src/main/python/resource_management/libraries/functions/setup_atlas_hook.py ---------------------------------------------------------------------- diff --git a/ambari-common/src/main/python/resource_management/libraries/functions/setup_atlas_hook.py b/ambari-common/src/main/python/resource_management/libraries/functions/setup_atlas_hook.py index 367afc8..985eb37 100644 --- a/ambari-common/src/main/python/resource_management/libraries/functions/setup_atlas_hook.py +++ b/ambari-common/src/main/python/resource_management/libraries/functions/setup_atlas_hook.py @@ -162,14 +162,9 @@ def setup_atlas_jar_symlinks(hook_name, jar_source_dir): import params stack_root = Script.get_stack_root() - atlas_home_dir = os.path.join(stack_root, "current", "atlas-server") - - # if this is an upgrade/downagrade, then we must link in the correct version - # which may not be "current", so change the home directory location - upgrade_type = Script.get_upgrade_type(default("/commandParams/upgrade_type", "")) - if upgrade_type is not None: - version_dir_segment = stack_features.get_stack_feature_version(Script.get_config()) - atlas_home_dir = os.path.join(stack_root, version_dir_segment, "atlas") + atlas_component_name = "atlas" + stack_version = stack_features.get_stack_feature_version(Script.get_config()) + atlas_home_dir = os.path.join(stack_root, stack_version, atlas_component_name) # Will only exist if this host contains Atlas Server atlas_hook_dir = os.path.join(atlas_home_dir, "hook", hook_name)