ambari git commit: AMBARI-12979. Devdeploy:Start Services fails at enabling security (aonishuk)
Repository: ambari Updated Branches: refs/heads/branch-2.1 3e9e182d6 -> 189beebd3 AMBARI-12979. Devdeploy:Start Services fails at enabling security (aonishuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/189beebd Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/189beebd Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/189beebd Branch: refs/heads/branch-2.1 Commit: 189beebd34476f392c39a7e02e7df40c0f46ab6e Parents: 3e9e182 Author: Andrew OnishukAuthored: Wed Sep 2 18:52:55 2015 +0300 Committer: Andrew Onishuk Committed: Wed Sep 2 18:52:55 2015 +0300 -- .../0.5.0.2.2/package/scripts/params_linux.py | 12 .../python/stacks/2.2/KNOX/test_knox_gateway.py | 20 ++-- 2 files changed, 18 insertions(+), 14 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/189beebd/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py -- diff --git a/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py b/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py index 5917cda..27a71a2 100644 --- a/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py +++ b/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py @@ -40,6 +40,10 @@ knox_master_secret_path = '/var/lib/knox/data/security/master' knox_cert_store_path = '/var/lib/knox/data/security/keystores/gateway.jks' knox_user = default("/configurations/knox-env/knox_user", "knox") +# server configurations +knox_data_dir = '/var/lib/knox/data' +knox_logs_dir = '/var/log/knox' + # default parameters knox_bin = '/usr/bin/gateway' knox_conf_dir = '/etc/knox/conf' @@ -53,13 +57,13 @@ if Script.is_hdp_stack_greater_or_equal("2.2"): ldap_bin = '/usr/hdp/current/knox-server/bin/ldap.sh' knox_client_bin = '/usr/hdp/current/knox-server/bin/knoxcli.sh' + knox_master_secret_path = '/usr/hdp/current/knox-server/data/security/master' + knox_cert_store_path = '/usr/hdp/current/knox-server/data/security/keystores/gateway.jks' + knox_data_dir = '/usr/hdp/current/knox-server/data' + knox_group = default("/configurations/knox-env/knox_group", "knox") mode = 0644 -# server configurations -knox_data_dir = '/var/lib/knox/data' -knox_logs_dir = '/var/log/knox' - stack_version_unformatted = str(config['hostLevelParams']['stack_version']) hdp_stack_version = format_hdp_stack_version(stack_version_unformatted) http://git-wip-us.apache.org/repos/asf/ambari/blob/189beebd/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py -- diff --git a/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py b/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py index 11f476e..2acd4053 100644 --- a/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py +++ b/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py @@ -39,7 +39,7 @@ class TestKnoxGateway(RMFTestCase): target = RMFTestCase.TARGET_COMMON_SERVICES ) -self.assertResourceCalled('Directory', '/var/lib/knox/data', +self.assertResourceCalled('Directory', '/usr/hdp/current/knox-server/data', owner = 'knox', group = 'knox', recursive = True @@ -87,7 +87,7 @@ class TestKnoxGateway(RMFTestCase): self.assertResourceCalled('Execute', ('chown', '-R', 'knox:knox', - '/var/lib/knox/data', + '/usr/hdp/current/knox-server/data', '/var/log/knox', '/var/run/knox', '/usr/hdp/current/knox-server/conf', @@ -96,12 +96,12 @@ class TestKnoxGateway(RMFTestCase): ) self.assertResourceCalled('Execute', '/usr/hdp/current/knox-server/bin/knoxcli.sh create-master --master sa', environment = {'JAVA_HOME': u'/usr/jdk64/jdk1.7.0_45'}, -not_if = "ambari-sudo.sh su knox -l -s /bin/bash -c '[RMF_EXPORT_PLACEHOLDER]test -f /var/lib/knox/data/security/master'", +not_if = "ambari-sudo.sh su knox -l -s /bin/bash -c '[RMF_EXPORT_PLACEHOLDER]test -f /usr/hdp/current/knox-server/data/security/master'", user = 'knox', ) self.assertResourceCalled('Execute', '/usr/hdp/current/knox-server/bin/knoxcli.sh create-cert --hostname c6401.ambari.apache.org', environment = {'JAVA_HOME': u'/usr/jdk64/jdk1.7.0_45'}, -not_if = "ambari-sudo.sh su knox -l -s /bin/bash -c '[RMF_EXPORT_PLACEHOLDER]test -f
ambari git commit: AMBARI-12018. JCE distribution should be done as part of Kerberos service configure function instead from hooks (refactoring) (Emil Anca via rlevas)
Repository: ambari Updated Branches: refs/heads/branch-2.1 189beebd3 -> 113a0b602 AMBARI-12018. JCE distribution should be done as part of Kerberos service configure function instead from hooks (refactoring) (Emil Anca via rlevas) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/113a0b60 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/113a0b60 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/113a0b60 Branch: refs/heads/branch-2.1 Commit: 113a0b602f59f03a05851ad4f4bfcec7d8f00d57 Parents: 189beeb Author: Emil AncaAuthored: Mon Jun 22 11:22:39 2015 -0400 Committer: Jayush Luniya Committed: Wed Sep 2 09:07:19 2015 -0700 -- .../package/scripts/kerberos_client.py | 6 .../package/scripts/kerberos_common.py | 33 +++ .../1.10.3-10/package/scripts/params.py | 9 ++ .../HDP/2.0.6/hooks/before-ANY/scripts/hook.py | 3 +- .../2.0.6/hooks/before-ANY/scripts/params.py| 2 -- .../before-ANY/scripts/shared_initialization.py | 34 .../2.0.6/hooks/before-ANY/test_before_any.py | 7 +--- .../stacks/2.2/KERBEROS/test_kerberos_client.py | 6 8 files changed, 56 insertions(+), 44 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/113a0b60/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_client.py -- diff --git a/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_client.py b/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_client.py index 282915a..580545d 100644 --- a/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_client.py +++ b/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_client.py @@ -37,6 +37,8 @@ class KerberosClient(KerberosScript): if params.manage_krb5_conf: self.write_krb5_conf() +self.setup_jce() + def status(self, env): raise ClientComponentHasNoStatus() @@ -67,5 +69,9 @@ class KerberosClient(KerberosScript): def remove_keytab(self, env): self.delete_keytab_file() + def download_install_jce(self, env): +self.setup_jce() + + if __name__ == "__main__": KerberosClient().execute() http://git-wip-us.apache.org/repos/asf/ambari/blob/113a0b60/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_common.py -- diff --git a/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_common.py b/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_common.py index cd9b2ba..d40627a 100644 --- a/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_common.py +++ b/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/kerberos_common.py @@ -428,3 +428,36 @@ class KerberosScript(Script): curr_content['keytabs'][principal.replace("_HOST", params.hostname)] = '_REMOVED_' self.put_structured_out(curr_content) + + def setup_jce(self): +import params + +if not params.jdk_name: + return +jce_curl_target = None +if params.jce_policy_zip is not None: + jce_curl_target = format("{artifact_dir}/{jce_policy_zip}") + Directory(params.artifact_dir, +recursive = True, +) + File(jce_curl_target, + content = DownloadSource(format("{jce_location}/{jce_policy_zip}")), + ) +elif params.security_enabled: + # Something weird is happening + raise Fail("Security is enabled, but JCE policy zip is not specified.") + +# The extraction will occur only after the security flag is set +if params.security_enabled: + security_dir = format("{java_home}/jre/lib/security") + + File([format("{security_dir}/US_export_policy.jar"), format("{security_dir}/local_policy.jar")], + action = "delete", + ) + + extract_cmd = ("unzip", "-o", "-j", "-q", jce_curl_target, "-d", security_dir) + Execute(extract_cmd, + only_if = format("test -e {security_dir} && test -f {jce_curl_target}"), + path = ['/bin/','/usr/bin'], + sudo = True + ) http://git-wip-us.apache.org/repos/asf/ambari/blob/113a0b60/ambari-server/src/main/resources/common-services/KERBEROS/1.10.3-10/package/scripts/params.py -- diff --git
ambari git commit: AMBARI-12969. sys_prepped clusters should not have to copy tarballs again
Repository: ambari Updated Branches: refs/heads/branch-2.1.1 7a42cb108 -> 40f819e6b AMBARI-12969. sys_prepped clusters should not have to copy tarballs again Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/40f819e6 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/40f819e6 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/40f819e6 Branch: refs/heads/branch-2.1.1 Commit: 40f819e6bae3805fafef192f2f231f0aca30cdec Parents: 7a42cb1 Author: Sumit MohantyAuthored: Wed Sep 2 09:35:42 2015 -0700 Committer: Sumit Mohanty Committed: Wed Sep 2 09:39:27 2015 -0700 -- .../libraries/functions/copy_tarball.py | 9 +++-- .../HIVE/0.12.0.2.0/package/scripts/hive.py | 13 - .../HIVE/0.12.0.2.0/package/scripts/hive_server.py | 12 ++-- .../PIG/0.12.0.2.0/package/scripts/service_check.py | 5 - .../1.2.0.2.2/package/scripts/job_history_server.py | 6 +- .../1.2.0.2.2/package/scripts/spark_service.py | 2 +- .../TEZ/0.4.0.2.1/package/scripts/pre_upgrade.py| 7 ++- .../TEZ/0.4.0.2.1/package/scripts/service_check.py | 2 +- .../YARN/2.1.0.2.0/package/scripts/historyserver.py | 16 .../python/stacks/2.0.6/HIVE/test_hive_server.py| 8 .../python/stacks/2.0.6/YARN/test_historyserver.py | 2 +- .../python/stacks/2.2/PIG/test_pig_service_check.py | 2 +- 12 files changed, 60 insertions(+), 24 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/40f819e6/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py -- diff --git a/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py b/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py index ad4aadc..7690485 100644 --- a/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py +++ b/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py @@ -96,7 +96,7 @@ def _get_single_version_from_hdp_select(): return hdp_version def copy_to_hdfs(name, user_group, owner, file_mode=0444, custom_source_file=None, custom_dest_file=None, force_execute=False, - use_ru_version_during_ru=True): + use_ru_version_during_ru=True, host_sys_prepped=False): """ :param name: Tarball name, e.g., tez, hive, pig, sqoop. :param user_group: Group to own the directory. @@ -106,6 +106,7 @@ def copy_to_hdfs(name, user_group, owner, file_mode=0444, custom_source_file=Non :param custom_dest_file: Override the destination file path :param force_execute: If true, will execute the HDFS commands immediately, otherwise, will defer to the calling function. :param use_ru_version_during_ru: If true, will use the version going to during RU. Otherwise, use the CURRENT (source) version. + :param host_sys_prepped: If true, tarballs will not be copied as the cluster deployment uses prepped VMs. :return: Will return True if successful, otherwise, False. """ import params @@ -127,6 +128,10 @@ def copy_to_hdfs(name, user_group, owner, file_mode=0444, custom_source_file=Non if custom_dest_file is not None: dest_file = custom_dest_file + if host_sys_prepped: +Logger.info("Skipping copying {0} to {1} for {2} as its a sys_prepped host.".format(str(source_file), str(dest_file), str(name))) +return True + upgrade_direction = default("/commandParams/upgrade_direction", None) is_rolling_upgrade = upgrade_direction is not None current_version = default("/hostLevelParams/current_version", None) @@ -199,4 +204,4 @@ def copy_to_hdfs(name, user_group, owner, file_mode=0444, custom_source_file=Non if force_execute: params.HdfsResource(None, action="execute") - return True \ No newline at end of file + return True http://git-wip-us.apache.org/repos/asf/ambari/blob/40f819e6/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py -- diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py index 6081b39..389909c 100644 --- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py +++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py @@ -131,8 +131,8 @@ def hive(name=None): # * # HDP 2.2 or higher, copy mapreduce.tar.gz to HDFS if params.hdp_stack_version_major != ""
ambari git commit: AMBARI-12969. sys_prepped clusters should not have to copy tarballs again
Repository: ambari Updated Branches: refs/heads/trunk d2e92bbdd -> c3d1306af AMBARI-12969. sys_prepped clusters should not have to copy tarballs again Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/c3d1306a Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/c3d1306a Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/c3d1306a Branch: refs/heads/trunk Commit: c3d1306af8683ef0a8528c3bdcadc33e012f484c Parents: d2e92bb Author: Sumit MohantyAuthored: Wed Sep 2 09:35:42 2015 -0700 Committer: Sumit Mohanty Committed: Wed Sep 2 09:35:42 2015 -0700 -- .../libraries/functions/copy_tarball.py | 9 +++-- .../HIVE/0.12.0.2.0/package/scripts/hive.py | 13 - .../HIVE/0.12.0.2.0/package/scripts/hive_server.py | 12 ++-- .../PIG/0.12.0.2.0/package/scripts/service_check.py | 5 - .../1.2.0.2.2/package/scripts/job_history_server.py | 6 +- .../1.2.0.2.2/package/scripts/spark_service.py | 2 +- .../TEZ/0.4.0.2.1/package/scripts/pre_upgrade.py| 7 ++- .../TEZ/0.4.0.2.1/package/scripts/service_check.py | 2 +- .../YARN/2.1.0.2.0/package/scripts/historyserver.py | 16 .../python/stacks/2.0.6/HIVE/test_hive_server.py| 8 .../python/stacks/2.0.6/YARN/test_historyserver.py | 2 +- .../python/stacks/2.2/PIG/test_pig_service_check.py | 2 +- 12 files changed, 60 insertions(+), 24 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/c3d1306a/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py -- diff --git a/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py b/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py index 792f019..badf2fe 100644 --- a/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py +++ b/ambari-common/src/main/python/resource_management/libraries/functions/copy_tarball.py @@ -96,7 +96,7 @@ def _get_single_version_from_hdp_select(): return hdp_version def copy_to_hdfs(name, user_group, owner, file_mode=0444, custom_source_file=None, custom_dest_file=None, force_execute=False, - use_ru_version_during_ru=True, replace_existing_files=False): + use_ru_version_during_ru=True, replace_existing_files=False, host_sys_prepped=False): """ :param name: Tarball name, e.g., tez, hive, pig, sqoop. :param user_group: Group to own the directory. @@ -106,6 +106,7 @@ def copy_to_hdfs(name, user_group, owner, file_mode=0444, custom_source_file=Non :param custom_dest_file: Override the destination file path :param force_execute: If true, will execute the HDFS commands immediately, otherwise, will defer to the calling function. :param use_ru_version_during_ru: If true, will use the version going to during RU. Otherwise, use the CURRENT (source) version. + :param host_sys_prepped: If true, tarballs will not be copied as the cluster deployment uses prepped VMs. :return: Will return True if successful, otherwise, False. """ import params @@ -127,6 +128,10 @@ def copy_to_hdfs(name, user_group, owner, file_mode=0444, custom_source_file=Non if custom_dest_file is not None: dest_file = custom_dest_file + if host_sys_prepped: +Logger.info("Skipping copying {0} to {1} for {2} as its a sys_prepped host.".format(str(source_file), str(dest_file), str(name))) +return True + upgrade_direction = default("/commandParams/upgrade_direction", None) is_rolling_upgrade = upgrade_direction is not None current_version = default("/hostLevelParams/current_version", None) @@ -200,4 +205,4 @@ def copy_to_hdfs(name, user_group, owner, file_mode=0444, custom_source_file=Non if force_execute: params.HdfsResource(None, action="execute") - return True \ No newline at end of file + return True http://git-wip-us.apache.org/repos/asf/ambari/blob/c3d1306a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py -- diff --git a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py index 1b2b155..7e35a57 100644 --- a/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py +++ b/ambari-server/src/main/resources/common-services/HIVE/0.12.0.2.0/package/scripts/hive.py @@ -132,8 +132,8 @@ def hive(name=None): # * # HDP 2.2 or higher, copy mapreduce.tar.gz to
ambari git commit: AMBARI-12979. Devdeploy:Start Services fails at enabling security (aonishuk)
Repository: ambari Updated Branches: refs/heads/trunk 133535e6e -> d2e92bbdd AMBARI-12979. Devdeploy:Start Services fails at enabling security (aonishuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/d2e92bbd Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/d2e92bbd Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/d2e92bbd Branch: refs/heads/trunk Commit: d2e92bbdd6b99ba26a3e5da92359df6da85586c6 Parents: 133535e Author: Andrew OnishukAuthored: Wed Sep 2 18:52:02 2015 +0300 Committer: Andrew Onishuk Committed: Wed Sep 2 18:52:02 2015 +0300 -- .../0.5.0.2.2/package/scripts/params_linux.py | 12 .../python/stacks/2.2/KNOX/test_knox_gateway.py | 20 ++-- 2 files changed, 18 insertions(+), 14 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/d2e92bbd/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py -- diff --git a/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py b/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py index b39e780..ad7f672 100644 --- a/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py +++ b/ambari-server/src/main/resources/common-services/KNOX/0.5.0.2.2/package/scripts/params_linux.py @@ -40,6 +40,10 @@ knox_master_secret_path = '/var/lib/knox/data/security/master' knox_cert_store_path = '/var/lib/knox/data/security/keystores/gateway.jks' knox_user = default("/configurations/knox-env/knox_user", "knox") +# server configurations +knox_data_dir = '/var/lib/knox/data' +knox_logs_dir = '/var/log/knox' + # default parameters knox_bin = '/usr/bin/gateway' knox_conf_dir = '/etc/knox/conf' @@ -53,13 +57,13 @@ if Script.is_hdp_stack_greater_or_equal("2.2"): ldap_bin = '/usr/hdp/current/knox-server/bin/ldap.sh' knox_client_bin = '/usr/hdp/current/knox-server/bin/knoxcli.sh' + knox_master_secret_path = '/usr/hdp/current/knox-server/data/security/master' + knox_cert_store_path = '/usr/hdp/current/knox-server/data/security/keystores/gateway.jks' + knox_data_dir = '/usr/hdp/current/knox-server/data' + knox_group = default("/configurations/knox-env/knox_group", "knox") mode = 0644 -# server configurations -knox_data_dir = '/var/lib/knox/data' -knox_logs_dir = '/var/log/knox' - stack_version_unformatted = str(config['hostLevelParams']['stack_version']) hdp_stack_version = format_hdp_stack_version(stack_version_unformatted) http://git-wip-us.apache.org/repos/asf/ambari/blob/d2e92bbd/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py -- diff --git a/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py b/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py index 11f476e..2acd4053 100644 --- a/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py +++ b/ambari-server/src/test/python/stacks/2.2/KNOX/test_knox_gateway.py @@ -39,7 +39,7 @@ class TestKnoxGateway(RMFTestCase): target = RMFTestCase.TARGET_COMMON_SERVICES ) -self.assertResourceCalled('Directory', '/var/lib/knox/data', +self.assertResourceCalled('Directory', '/usr/hdp/current/knox-server/data', owner = 'knox', group = 'knox', recursive = True @@ -87,7 +87,7 @@ class TestKnoxGateway(RMFTestCase): self.assertResourceCalled('Execute', ('chown', '-R', 'knox:knox', - '/var/lib/knox/data', + '/usr/hdp/current/knox-server/data', '/var/log/knox', '/var/run/knox', '/usr/hdp/current/knox-server/conf', @@ -96,12 +96,12 @@ class TestKnoxGateway(RMFTestCase): ) self.assertResourceCalled('Execute', '/usr/hdp/current/knox-server/bin/knoxcli.sh create-master --master sa', environment = {'JAVA_HOME': u'/usr/jdk64/jdk1.7.0_45'}, -not_if = "ambari-sudo.sh su knox -l -s /bin/bash -c '[RMF_EXPORT_PLACEHOLDER]test -f /var/lib/knox/data/security/master'", +not_if = "ambari-sudo.sh su knox -l -s /bin/bash -c '[RMF_EXPORT_PLACEHOLDER]test -f /usr/hdp/current/knox-server/data/security/master'", user = 'knox', ) self.assertResourceCalled('Execute', '/usr/hdp/current/knox-server/bin/knoxcli.sh create-cert --hostname c6401.ambari.apache.org', environment = {'JAVA_HOME': u'/usr/jdk64/jdk1.7.0_45'}, -not_if = "ambari-sudo.sh su knox -l -s /bin/bash -c '[RMF_EXPORT_PLACEHOLDER]test -f
ambari git commit: AMBARI-12953: Ambari Agent logging set up incorrect (Nahappan Somasundaram via jluniya)
Repository: ambari Updated Branches: refs/heads/trunk 58fdcb5c9 -> 50b129498 AMBARI-12953: Ambari Agent logging set up incorrect (Nahappan Somasundaram via jluniya) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/50b12949 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/50b12949 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/50b12949 Branch: refs/heads/trunk Commit: 50b1294985c1c17d74ce12f4a814d51b8d0ad8c6 Parents: 58fdcb5 Author: Jayush LuniyaAuthored: Wed Sep 2 13:28:19 2015 -0700 Committer: Jayush Luniya Committed: Wed Sep 2 13:28:19 2015 -0700 -- ambari-agent/conf/unix/ambari-agent | 8 +++- .../test/python/ambari_agent/TestAmbariAgent.py | 43 2 files changed, 49 insertions(+), 2 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/50b12949/ambari-agent/conf/unix/ambari-agent -- diff --git a/ambari-agent/conf/unix/ambari-agent b/ambari-agent/conf/unix/ambari-agent index 9659014..f894c8e 100755 --- a/ambari-agent/conf/unix/ambari-agent +++ b/ambari-agent/conf/unix/ambari-agent @@ -93,8 +93,12 @@ if [ -a /var/lib/ambari-agent/ambari-env.sh ]; then . /var/lib/ambari-agent/ambari-env.sh fi -if [ ! -z $AMBARI_LOG_DIR ]; then - LOGFILE=$AMBARI_LOG_DIR/ambari-agent.log +if [ ! -z $AMBARI_AGENT_LOG_DIR ]; then + LOGFILE=$AMBARI_AGENT_LOG_DIR/ambari-agent.log +fi + +if [ ! -z $AMBARI_AGENT_OUT_DIR ]; then + OUTFILE=$AMBARI_AGENT_OUT_DIR/ambari-agent.out fi if [ -z $RESOLVED_AMBARI_PASSPHRASE ] && [ ! -z $AMBARI_PASSPHRASE ]; then http://git-wip-us.apache.org/repos/asf/ambari/blob/50b12949/ambari-agent/src/test/python/ambari_agent/TestAmbariAgent.py -- diff --git a/ambari-agent/src/test/python/ambari_agent/TestAmbariAgent.py b/ambari-agent/src/test/python/ambari_agent/TestAmbariAgent.py index a7ee104..a354572 100644 --- a/ambari-agent/src/test/python/ambari_agent/TestAmbariAgent.py +++ b/ambari-agent/src/test/python/ambari_agent/TestAmbariAgent.py @@ -22,6 +22,7 @@ import unittest import subprocess import os import sys +import AmbariConfig from mock.mock import MagicMock, patch, ANY with patch("platform.linux_distribution", return_value = ('Suse','11','Final')): from ambari_agent.Controller import AGENT_AUTO_RESTART_EXIT_CODE @@ -52,3 +53,45 @@ class TestAmbariAgent(unittest.TestCase): self.assertTrue(os_path_isfile_mock.called) self.assertTrue(os_path_isfile_mock.call_count == 2) self.assertTrue(os_remove_mock.called) + + # + # Test AmbariConfig.getLogFile() for ambari-agent + # + def test_logfile_location(self): +# +# Test without $AMBARI_AGENT_LOG_DIR +# +log_folder = '/var/log/ambari-agent' +log_file = 'ambari-agent.log' +with patch.dict('os.environ', {}): + self.assertEqual(os.path.join(log_folder, log_file), AmbariConfig.AmbariConfig.getLogFile()) + +# +# Test with $AMBARI_AGENT_LOG_DIR +# +log_folder = '/myloglocation/log' +log_file = 'ambari-agent.log' +with patch.dict('os.environ', {'AMBARI_AGENT_LOG_DIR': log_folder}): + self.assertEqual(os.path.join(log_folder, log_file), AmbariConfig.AmbariConfig.getLogFile()) +pass + + # + # Test AmbariConfig.getOutFile() for ambari-agent + # + def test_outfile_location(self): +# +# Test without $AMBARI_AGENT_OUT_DIR +# +out_folder = '/var/log/ambari-agent' +out_file = 'ambari-agent.out' +with patch.dict('os.environ', {}): + self.assertEqual(os.path.join(out_folder, out_file), AmbariConfig.AmbariConfig.getOutFile()) + +# +# Test with $AMBARI_AGENT_OUT_DIR +# +out_folder = '/myoutlocation/out' +out_file = 'ambari-agent.out' +with patch.dict('os.environ', {'AMBARI_AGENT_OUT_DIR': out_folder}): + self.assertEqual(os.path.join(out_folder, out_file), AmbariConfig.AmbariConfig.getOutFile()) +pass
ambari git commit: AMBARI-12987. Edit button on Admin->kerberos page does not work. (jaimin)
Repository: ambari Updated Branches: refs/heads/trunk b838dcfb0 -> b9a0b39ca AMBARI-12987. Edit button on Admin->kerberos page does not work. (jaimin) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/b9a0b39c Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/b9a0b39c Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/b9a0b39c Branch: refs/heads/trunk Commit: b9a0b39ca3390f4a0879d048bf1fbf6be4d73929 Parents: b838dcf Author: Jaimin JetlyAuthored: Wed Sep 2 18:07:41 2015 -0700 Committer: Jaimin Jetly Committed: Wed Sep 2 18:08:49 2015 -0700 -- ambari-web/app/controllers/main/admin/kerberos.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/b9a0b39c/ambari-web/app/controllers/main/admin/kerberos.js -- diff --git a/ambari-web/app/controllers/main/admin/kerberos.js b/ambari-web/app/controllers/main/admin/kerberos.js index f4d2428..2336708 100644 --- a/ambari-web/app/controllers/main/admin/kerberos.js +++ b/ambari-web/app/controllers/main/admin/kerberos.js @@ -466,7 +466,7 @@ App.MainAdminKerberosController = App.KerberosWizardStep4Controller.extend({ makeConfigsEditable: function () { -if (!this.get('stepConfigs') || !this.get('stepConfigs.length')) { +if (this.get('stepConfigs') && this.get('stepConfigs.length')) { this.set('isEditMode', true); this.get('stepConfigs').forEach(function (_stepConfig) { _stepConfig.get('configs').setEach('isEditable', true);
ambari git commit: AMBARI-12987. Edit button on Admin->kerberos page does not work. (jaimin)
Repository: ambari Updated Branches: refs/heads/branch-2.1 7cf17e444 -> 77529726a AMBARI-12987. Edit button on Admin->kerberos page does not work. (jaimin) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/77529726 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/77529726 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/77529726 Branch: refs/heads/branch-2.1 Commit: 77529726ae32801b8c0658d7962cf15cac4abd30 Parents: 7cf17e4 Author: Jaimin JetlyAuthored: Wed Sep 2 18:07:41 2015 -0700 Committer: Jaimin Jetly Committed: Wed Sep 2 18:08:17 2015 -0700 -- ambari-web/app/controllers/main/admin/kerberos.js | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/77529726/ambari-web/app/controllers/main/admin/kerberos.js -- diff --git a/ambari-web/app/controllers/main/admin/kerberos.js b/ambari-web/app/controllers/main/admin/kerberos.js index ab4b2db..bbad706 100644 --- a/ambari-web/app/controllers/main/admin/kerberos.js +++ b/ambari-web/app/controllers/main/admin/kerberos.js @@ -466,7 +466,7 @@ App.MainAdminKerberosController = App.KerberosWizardStep4Controller.extend({ makeConfigsEditable: function () { -if (!this.get('stepConfigs') || !this.get('stepConfigs.length')) { +if (this.get('stepConfigs') && this.get('stepConfigs.length')) { this.set('isEditMode', true); this.get('stepConfigs').forEach(function (_stepConfig) { _stepConfig.get('configs').setEach('isEditable', true);
ambari git commit: AMBARI-12615. Add Data Visualization to Hive View. (Vivek Ratnavel Subramanian)
Repository: ambari Updated Branches: refs/heads/branch-2.1 77529726a -> e54a453cd AMBARI-12615. Add Data Visualization to Hive View. (Vivek Ratnavel Subramanian) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/e54a453c Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/e54a453c Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/e54a453c Branch: refs/heads/branch-2.1 Commit: e54a453cdfa4baff374a548236ff777b8375f3ee Parents: 7752972 Author: Yusaku SakoAuthored: Wed Aug 5 23:27:52 2015 -0700 Committer: Yusaku Sako Committed: Wed Sep 2 21:34:46 2015 -0700 -- ambari-web/app/views/main/views/details.js | 4 +- contrib/views/hive/pom.xml | 11 ++- .../resources/browser/HiveBrowserService.java | 41 +- .../view/hive/resources/jobs/JobService.java| 3 +- .../jobs/ResultsPaginationController.java | 39 +++--- .../src/main/resources/ui/hive-web/.jshintrc| 3 +- .../app/components/visualization-tabs-widget.js | 56 ++ .../ui/hive-web/app/controllers/query-tabs.js | 10 +++ .../app/controllers/visualization-ui.js | 79 .../ui/hive-web/app/initializers/i18n.js| 4 +- .../components/visualization-tabs-widget.hbs| 27 +++ .../hive-web/app/templates/visualization-ui.hbs | 32 .../ui/hive-web/app/utils/constants.js | 7 +- .../ui/hive-web/app/views/visualization-ui.js | 37 + .../src/main/resources/ui/hive-web/bower.json | 4 +- 15 files changed, 319 insertions(+), 38 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/e54a453c/ambari-web/app/views/main/views/details.js -- diff --git a/ambari-web/app/views/main/views/details.js b/ambari-web/app/views/main/views/details.js index e90cb20..956ac71 100644 --- a/ambari-web/app/views/main/views/details.js +++ b/ambari-web/app/views/main/views/details.js @@ -24,9 +24,9 @@ App.MainViewsDetailsView = Em.View.extend({ tagName: "iframe", classNames: ["views_sizes"], - attributeBindings: ['src','seamless'], + attributeBindings: ['src','seamless','allowfullscreen'], seamless: "seamless", - + allowfullscreen: "true", interval: null, /** http://git-wip-us.apache.org/repos/asf/ambari/blob/e54a453c/contrib/views/hive/pom.xml -- diff --git a/contrib/views/hive/pom.xml b/contrib/views/hive/pom.xml index dc0d5f6..455ab32 100644 --- a/contrib/views/hive/pom.xml +++ b/contrib/views/hive/pom.xml @@ -240,7 +240,6 @@ - exec-maven-plugin org.codehaus.mojo @@ -318,6 +317,16 @@ false + src/main/resources/ui/hive-web/bower_components/polestar +false +polestar + + + src/main/resources/ui/hive-web/bower_components/voyager +false +voyager + + WEB-INF/lib false target/lib http://git-wip-us.apache.org/repos/asf/ambari/blob/e54a453c/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/browser/HiveBrowserService.java -- diff --git a/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/browser/HiveBrowserService.java b/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/browser/HiveBrowserService.java index a0d44f5..55919a7 100644 --- a/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/browser/HiveBrowserService.java +++ b/contrib/views/hive/src/main/java/org/apache/ambari/view/hive/resources/browser/HiveBrowserService.java @@ -113,6 +113,7 @@ public class HiveBrowserService { @QueryParam("first") String fromBeginning, @QueryParam("count") Integer count, @QueryParam("searchId") String searchId, +@QueryParam("format") String format, @QueryParam("columns") final String requestedColumns) { if (like == null) like = "*"; @@ -122,14 +123,14 @@ public class HiveBrowserService { try { final String finalLike = like; return ResultsPaginationController.getInstance(context) - .request("databases", searchId, false, fromBeginning, count, - new Callable() { -@Override -public Cursor call() throws Exception { - TSessionHandle session = getConnectionFactory().getHiveConnection().getOrCreateSessionByTag("DDL"); - return
ambari git commit: AMBARI-12982. Ambari-server 'mvn clean test' fails when Python 2.6 is picked up (aonishuk)
Repository: ambari Updated Branches: refs/heads/trunk c3d1306af -> 58fdcb5c9 AMBARI-12982. Ambari-server 'mvn clean test' fails when Python 2.6 is picked up (aonishuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/58fdcb5c Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/58fdcb5c Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/58fdcb5c Branch: refs/heads/trunk Commit: 58fdcb5c9224d3ecfd133f7a453a32d48fc74c2d Parents: c3d1306 Author: Andrew OnishukAuthored: Wed Sep 2 21:46:49 2015 +0300 Committer: Andrew Onishuk Committed: Wed Sep 2 21:46:49 2015 +0300 -- .../package/scripts/oozie_server_upgrade.py| 6 -- .../python/stacks/2.0.6/OOZIE/test_oozie_server.py | 17 ++--- 2 files changed, 18 insertions(+), 5 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/58fdcb5c/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py -- diff --git a/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py b/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py index 78d25bc..326e76c 100644 --- a/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py +++ b/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py @@ -22,11 +22,11 @@ import shutil import tempfile from resource_management.core import shell -from resource_management.core import sudo from resource_management.core.logger import Logger from resource_management.core.exceptions import Fail from resource_management.core.resources.system import Execute from resource_management.core.resources.system import Directory +from resource_management.core.resources.system import File from resource_management.libraries.functions import Direction from resource_management.libraries.functions import format from resource_management.libraries.functions import compare_versions @@ -154,7 +154,9 @@ class OozieUpgrade(Script): Logger.info("Copying {0} to {1}".format(oozie_ext_zip_file, params.oozie_libext_dir)) Execute(("cp", oozie_ext_zip_file, params.oozie_libext_dir), sudo=True) Execute(("chown", format("{oozie_user}:{user_group}"), oozie_ext_zip_target_path), sudo=True) -sudo.chmod(oozie_ext_zip_target_path, 0644) +File(oozie_ext_zip_target_path, + mode=0644 +) # Redownload jdbc driver to a new current location oozie.download_database_library_if_needed() http://git-wip-us.apache.org/repos/asf/ambari/blob/58fdcb5c/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py -- diff --git a/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py b/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py index 24ee07a..cf1c3d4 100644 --- a/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py +++ b/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py @@ -1174,6 +1174,9 @@ class TestOozieServer(RMFTestCase): self.assertResourceCalled('Directory', '/usr/hdp/current/oozie-server/libext', mode = 0777) self.assertResourceCalled('Execute', ('cp', '/usr/share/HDP-oozie/ext-2.2.zip', '/usr/hdp/current/oozie-server/libext'), sudo=True) self.assertResourceCalled('Execute', ('chown', 'oozie:hadoop', '/usr/hdp/current/oozie-server/libext/ext-2.2.zip'), sudo=True) +self.assertResourceCalled('File', '/usr/hdp/current/oozie-server/libext/ext-2.2.zip', +mode = 0644, +) self.assertNoMoreResources() @patch("os.path.isdir") @@ -1239,11 +1242,13 @@ class TestOozieServer(RMFTestCase): self.assertResourceCalled('Execute', ('cp', '/usr/share/HDP-oozie/ext-2.2.zip', '/usr/hdp/current/oozie-server/libext'), sudo=True) self.assertResourceCalled('Execute', ('chown', 'oozie:hadoop', '/usr/hdp/current/oozie-server/libext/ext-2.2.zip'), sudo=True) - +self.assertResourceCalled('File', '/usr/hdp/current/oozie-server/libext/ext-2.2.zip', +mode = 0644, +) self.assertNoMoreResources() self.assertEquals(1, mocks_dict['call'].call_count) -self.assertEquals(2, mocks_dict['checked_call'].call_count) +self.assertEquals(1, mocks_dict['checked_call'].call_count) self.assertEquals( ('conf-select', 'set-conf-dir', '--package', 'oozie', '--stack-version', '2.3.0.0-1234', '--conf-version', '0'), @@ -1294,6 +1299,9 @@ class TestOozieServer(RMFTestCase):
ambari git commit: AMBARI-12982. Ambari-server 'mvn clean test' fails when Python 2.6 is picked up (aonishuk)
Repository: ambari Updated Branches: refs/heads/branch-2.1 31edfe3ba -> a17c31abb AMBARI-12982. Ambari-server 'mvn clean test' fails when Python 2.6 is picked up (aonishuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/a17c31ab Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/a17c31ab Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/a17c31ab Branch: refs/heads/branch-2.1 Commit: a17c31abbf58e830c4966b4c37b92af5b240f00f Parents: 31edfe3 Author: Andrew OnishukAuthored: Wed Sep 2 21:43:04 2015 +0300 Committer: Andrew Onishuk Committed: Wed Sep 2 21:43:04 2015 +0300 -- .../package/scripts/oozie_server_upgrade.py | 6 -- .../stacks/2.0.6/OOZIE/test_oozie_server.py | 18 +++--- .../stacks/2.0.6/common/test_stack_advisor.py | 6 +++--- 3 files changed, 22 insertions(+), 8 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/a17c31ab/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py -- diff --git a/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py b/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py index 78d25bc..326e76c 100644 --- a/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py +++ b/ambari-server/src/main/resources/common-services/OOZIE/4.0.0.2.0/package/scripts/oozie_server_upgrade.py @@ -22,11 +22,11 @@ import shutil import tempfile from resource_management.core import shell -from resource_management.core import sudo from resource_management.core.logger import Logger from resource_management.core.exceptions import Fail from resource_management.core.resources.system import Execute from resource_management.core.resources.system import Directory +from resource_management.core.resources.system import File from resource_management.libraries.functions import Direction from resource_management.libraries.functions import format from resource_management.libraries.functions import compare_versions @@ -154,7 +154,9 @@ class OozieUpgrade(Script): Logger.info("Copying {0} to {1}".format(oozie_ext_zip_file, params.oozie_libext_dir)) Execute(("cp", oozie_ext_zip_file, params.oozie_libext_dir), sudo=True) Execute(("chown", format("{oozie_user}:{user_group}"), oozie_ext_zip_target_path), sudo=True) -sudo.chmod(oozie_ext_zip_target_path, 0644) +File(oozie_ext_zip_target_path, + mode=0644 +) # Redownload jdbc driver to a new current location oozie.download_database_library_if_needed() http://git-wip-us.apache.org/repos/asf/ambari/blob/a17c31ab/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py -- diff --git a/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py b/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py index 24ee07a..3341511 100644 --- a/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py +++ b/ambari-server/src/test/python/stacks/2.0.6/OOZIE/test_oozie_server.py @@ -1174,6 +1174,9 @@ class TestOozieServer(RMFTestCase): self.assertResourceCalled('Directory', '/usr/hdp/current/oozie-server/libext', mode = 0777) self.assertResourceCalled('Execute', ('cp', '/usr/share/HDP-oozie/ext-2.2.zip', '/usr/hdp/current/oozie-server/libext'), sudo=True) self.assertResourceCalled('Execute', ('chown', 'oozie:hadoop', '/usr/hdp/current/oozie-server/libext/ext-2.2.zip'), sudo=True) +self.assertResourceCalled('File', '/usr/hdp/current/oozie-server/libext/ext-2.2.zip', +mode = 0644, +) self.assertNoMoreResources() @patch("os.path.isdir") @@ -1239,11 +1242,13 @@ class TestOozieServer(RMFTestCase): self.assertResourceCalled('Execute', ('cp', '/usr/share/HDP-oozie/ext-2.2.zip', '/usr/hdp/current/oozie-server/libext'), sudo=True) self.assertResourceCalled('Execute', ('chown', 'oozie:hadoop', '/usr/hdp/current/oozie-server/libext/ext-2.2.zip'), sudo=True) - +self.assertResourceCalled('File', '/usr/hdp/current/oozie-server/libext/ext-2.2.zip', +mode = 0644, +) self.assertNoMoreResources() self.assertEquals(1, mocks_dict['call'].call_count) -self.assertEquals(2, mocks_dict['checked_call'].call_count) +self.assertEquals(1, mocks_dict['checked_call'].call_count) self.assertEquals( ('conf-select', 'set-conf-dir', '--package', 'oozie', '--stack-version', '2.3.0.0-1234', '--conf-version', '0'), @@ -1294,6
ambari git commit: AMBARI-12962. New ambari-agent logging infra makes it difficult to attach a log4j appender (aonishuk)
Repository: ambari Updated Branches: refs/heads/branch-2.1.1 40f819e6b -> 57ad39903 AMBARI-12962. New ambari-agent logging infra makes it difficult to attach a log4j appender (aonishuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/57ad3990 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/57ad3990 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/57ad3990 Branch: refs/heads/branch-2.1.1 Commit: 57ad39903aec0857d1dda9cb66ab4fa2f2a3c29f Parents: 40f819e Author: Andrew OnishukAuthored: Tue Sep 1 18:02:49 2015 +0300 Committer: Sumit Mohanty Committed: Wed Sep 2 12:52:35 2015 -0700 -- ambari-agent/src/main/python/ambari_agent/main.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/57ad3990/ambari-agent/src/main/python/ambari_agent/main.py -- diff --git a/ambari-agent/src/main/python/ambari_agent/main.py b/ambari-agent/src/main/python/ambari_agent/main.py index 3c2933e..fb5b4b1 100644 --- a/ambari-agent/src/main/python/ambari_agent/main.py +++ b/ambari-agent/src/main/python/ambari_agent/main.py @@ -45,7 +45,7 @@ from ambari_commons import shell import HeartbeatHandlers from HeartbeatHandlers import bind_signal_handlers from ambari_commons.constants import AMBARI_SUDO_BINARY -logger = logging.getLogger(__name__) +logger = logging.getLogger() formatstr = "%(levelname)s %(asctime)s %(filename)s:%(lineno)d - %(message)s" agentPid = os.getpid()
ambari git commit: AMBARI-12968. Hosts page 'clear filters' link does not work (rzang)
Repository: ambari Updated Branches: refs/heads/trunk 0fde6a747 -> b838dcfb0 AMBARI-12968. Hosts page 'clear filters' link does not work (rzang) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/b838dcfb Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/b838dcfb Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/b838dcfb Branch: refs/heads/trunk Commit: b838dcfb0d43360e1a7116820bd12d7370922bd0 Parents: 0fde6a7 Author: Richard ZangAuthored: Wed Sep 2 11:38:12 2015 -0700 Committer: Richard Zang Committed: Wed Sep 2 16:06:44 2015 -0700 -- ambari-web/app/views/common/table_view.js | 2 +- .../app/views/main/alert_definitions_view.js| 2 +- ambari-web/app/views/main/host.js | 21 ++-- .../views/main/alert_definitions_view_test.js | 8 4 files changed, 25 insertions(+), 8 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/b838dcfb/ambari-web/app/views/common/table_view.js -- diff --git a/ambari-web/app/views/common/table_view.js b/ambari-web/app/views/common/table_view.js index 12bf9f3..7c0a2b4 100644 --- a/ambari-web/app/views/common/table_view.js +++ b/ambari-web/app/views/common/table_view.js @@ -384,7 +384,7 @@ App.TableView = Em.View.extend(App.UserPref, { }); }, - clearFilterCondition: function() { + clearFilterConditionsFromLocalStorage: function() { var result = false; var currentFCs = App.db.getFilterConditions(this.get('controller.name')); if (currentFCs != null) { http://git-wip-us.apache.org/repos/asf/ambari/blob/b838dcfb/ambari-web/app/views/main/alert_definitions_view.js -- diff --git a/ambari-web/app/views/main/alert_definitions_view.js b/ambari-web/app/views/main/alert_definitions_view.js index 189f71d..803fa63 100644 --- a/ambari-web/app/views/main/alert_definitions_view.js +++ b/ambari-web/app/views/main/alert_definitions_view.js @@ -38,7 +38,7 @@ App.MainAlertDefinitionsView = App.TableView.extend({ willInsertElement: function () { if (!this.get('controller.showFilterConditionsFirstLoad')) { - this.clearFilterCondition(); + this.clearFilterConditionsFromLocalStorage(); } this._super(); }, http://git-wip-us.apache.org/repos/asf/ambari/blob/b838dcfb/ambari-web/app/views/main/host.js -- diff --git a/ambari-web/app/views/main/host.js b/ambari-web/app/views/main/host.js index f63870f..7ff4c69 100644 --- a/ambari-web/app/views/main/host.js +++ b/ambari-web/app/views/main/host.js @@ -181,7 +181,7 @@ App.MainHostView = App.TableView.extend(App.TableServerViewMixin, { */ willInsertElement: function () { if (!this.get('controller.showFilterConditionsFirstLoad')) { - var didClearedSomething = this.clearFilterCondition(); + var didClearedSomething = this.clearFilterConditionsFromLocalStorage(); this.set('controller.filterChangeHappened', didClearedSomething); } this._super(); @@ -1174,5 +1174,22 @@ App.MainHostView = App.TableView.extend(App.TableServerViewMixin, { */ colPropAssoc: function () { return this.get('controller.colPropAssoc'); - }.property('controller.colPropAssoc') + }.property('controller.colPropAssoc'), + + /** + * Run clearFilter in the each child filterView + */ + clearFilters: function() { +// clean filters stored in-memory and local storage +this.set('filterConditions', []); +this.clearFilterConditionsFromLocalStorage(); +// clean UI +this.get('_childViews').forEach(function(childView) { + if (childView['clearFilter']) { +childView.clearFilter(); + } +}); +// force refresh +this.refresh(); + } }); http://git-wip-us.apache.org/repos/asf/ambari/blob/b838dcfb/ambari-web/test/views/main/alert_definitions_view_test.js -- diff --git a/ambari-web/test/views/main/alert_definitions_view_test.js b/ambari-web/test/views/main/alert_definitions_view_test.js index 0e8773c..c817e88 100644 --- a/ambari-web/test/views/main/alert_definitions_view_test.js +++ b/ambari-web/test/views/main/alert_definitions_view_test.js @@ -40,23 +40,23 @@ describe('App.MainAlertDefinitionsView', function () { describe('#willInsertElement', function () { beforeEach(function(){ - sinon.stub(view, 'clearFilterCondition', Em.K); + sinon.stub(view, 'clearFilterConditionsFromLocalStorage', Em.K); }); afterEach(function(){ - view.clearFilterCondition.restore(); +
ambari git commit: AMBARI-12985: Ranger KMS server install fails for PHD (jluniya)
Repository: ambari Updated Branches: refs/heads/branch-2.1.1 57ad39903 -> ab13984be AMBARI-12985: Ranger KMS server install fails for PHD (jluniya) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/ab13984b Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/ab13984b Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/ab13984b Branch: refs/heads/branch-2.1.1 Commit: ab13984beabc579c8d52378fbcfc23d4949dd429 Parents: 57ad399 Author: Jayush LuniyaAuthored: Wed Sep 2 16:04:37 2015 -0700 Committer: Jayush Luniya Committed: Wed Sep 2 16:06:52 2015 -0700 -- .../pluggable_stack_definition/configs/PHD.json | 32 ++-- ambari-web/app/data/custom_stack_map.js | 2 +- 2 files changed, 30 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/ab13984b/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json -- diff --git a/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json b/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json index ba6c964..45e45be 100644 --- a/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json +++ b/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json @@ -189,7 +189,16 @@ "name": "SPARK" }, { - "name": "RANGER" + "name": "RANGER", + "packages":[ +{ + "family": "redhat6,suse11", + "packages": [ +"ranger_3_0_*-admin", +"ranger_3_0_*-usersync" + ] +} + ] } ] }, @@ -325,10 +334,27 @@ "name": "SPARK" }, { - "name": "RANGER" + "name": "RANGER", + "packages":[ +{ + "family": "redhat6,redhat7,suse11", + "packages": [ +"ranger_3_3_*-admin", +"ranger_3_3_*-usersync" + ] +} + ] }, { - "name": "RANGER_KMS" + "name": "RANGER_KMS", + "packages":[ +{ + "family": "redhat6,redhat7,suse11", + "packages": [ +"ranger_3_3_*-kms" + ] +} + ] } ] } http://git-wip-us.apache.org/repos/asf/ambari/blob/ab13984b/ambari-web/app/data/custom_stack_map.js -- diff --git a/ambari-web/app/data/custom_stack_map.js b/ambari-web/app/data/custom_stack_map.js index 6994d8f..57991f1 100644 --- a/ambari-web/app/data/custom_stack_map.js +++ b/ambari-web/app/data/custom_stack_map.js @@ -32,7 +32,7 @@ Example: module.exports = [ { "stackName": "PHD", -"stackVersionNumber": "3.1", +"stackVersionNumber": "3.3", "sign": "=", "baseStackFolder": "HDP2.3" },
ambari git commit: AMBARI-12985: Ranger KMS server install fails for PHD (jluniya)
Repository: ambari Updated Branches: refs/heads/branch-2.1 a17c31abb -> 0d7682b0b AMBARI-12985: Ranger KMS server install fails for PHD (jluniya) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/0d7682b0 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/0d7682b0 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/0d7682b0 Branch: refs/heads/branch-2.1 Commit: 0d7682b0b81f949502942b4b3db23d7afa62c905 Parents: a17c31a Author: Jayush LuniyaAuthored: Wed Sep 2 16:04:37 2015 -0700 Committer: Jayush Luniya Committed: Wed Sep 2 16:05:22 2015 -0700 -- .../pluggable_stack_definition/configs/PHD.json | 32 ++-- ambari-web/app/data/custom_stack_map.js | 2 +- 2 files changed, 30 insertions(+), 4 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/0d7682b0/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json -- diff --git a/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json b/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json index ba6c964..45e45be 100644 --- a/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json +++ b/ambari-common/src/main/python/pluggable_stack_definition/configs/PHD.json @@ -189,7 +189,16 @@ "name": "SPARK" }, { - "name": "RANGER" + "name": "RANGER", + "packages":[ +{ + "family": "redhat6,suse11", + "packages": [ +"ranger_3_0_*-admin", +"ranger_3_0_*-usersync" + ] +} + ] } ] }, @@ -325,10 +334,27 @@ "name": "SPARK" }, { - "name": "RANGER" + "name": "RANGER", + "packages":[ +{ + "family": "redhat6,redhat7,suse11", + "packages": [ +"ranger_3_3_*-admin", +"ranger_3_3_*-usersync" + ] +} + ] }, { - "name": "RANGER_KMS" + "name": "RANGER_KMS", + "packages":[ +{ + "family": "redhat6,redhat7,suse11", + "packages": [ +"ranger_3_3_*-kms" + ] +} + ] } ] } http://git-wip-us.apache.org/repos/asf/ambari/blob/0d7682b0/ambari-web/app/data/custom_stack_map.js -- diff --git a/ambari-web/app/data/custom_stack_map.js b/ambari-web/app/data/custom_stack_map.js index 6994d8f..57991f1 100644 --- a/ambari-web/app/data/custom_stack_map.js +++ b/ambari-web/app/data/custom_stack_map.js @@ -32,7 +32,7 @@ Example: module.exports = [ { "stackName": "PHD", -"stackVersionNumber": "3.1", +"stackVersionNumber": "3.3", "sign": "=", "baseStackFolder": "HDP2.3" },
ambari git commit: AMBARI-12968. Hosts page 'clear filters' link does not work (rzang)
Repository: ambari Updated Branches: refs/heads/branch-2.1 0d7682b0b -> 7cf17e444 AMBARI-12968. Hosts page 'clear filters' link does not work (rzang) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/7cf17e44 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/7cf17e44 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/7cf17e44 Branch: refs/heads/branch-2.1 Commit: 7cf17e4440a6f29af0b728497a288b8afd78c6da Parents: 0d7682b Author: Richard ZangAuthored: Wed Sep 2 11:38:12 2015 -0700 Committer: Richard Zang Committed: Wed Sep 2 16:18:08 2015 -0700 -- ambari-web/app/views/common/table_view.js | 2 +- .../app/views/main/alert_definitions_view.js| 2 +- ambari-web/app/views/main/host.js | 21 ++-- .../views/main/alert_definitions_view_test.js | 8 4 files changed, 25 insertions(+), 8 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/7cf17e44/ambari-web/app/views/common/table_view.js -- diff --git a/ambari-web/app/views/common/table_view.js b/ambari-web/app/views/common/table_view.js index 12bf9f3..7c0a2b4 100644 --- a/ambari-web/app/views/common/table_view.js +++ b/ambari-web/app/views/common/table_view.js @@ -384,7 +384,7 @@ App.TableView = Em.View.extend(App.UserPref, { }); }, - clearFilterCondition: function() { + clearFilterConditionsFromLocalStorage: function() { var result = false; var currentFCs = App.db.getFilterConditions(this.get('controller.name')); if (currentFCs != null) { http://git-wip-us.apache.org/repos/asf/ambari/blob/7cf17e44/ambari-web/app/views/main/alert_definitions_view.js -- diff --git a/ambari-web/app/views/main/alert_definitions_view.js b/ambari-web/app/views/main/alert_definitions_view.js index 8c52a98..e67d124 100644 --- a/ambari-web/app/views/main/alert_definitions_view.js +++ b/ambari-web/app/views/main/alert_definitions_view.js @@ -38,7 +38,7 @@ App.MainAlertDefinitionsView = App.TableView.extend({ willInsertElement: function () { if (!this.get('controller.showFilterConditionsFirstLoad')) { - this.clearFilterCondition(); + this.clearFilterConditionsFromLocalStorage(); this.clearStartIndex(); } this.removeObserver('filteredCount', this, 'updatePaging'); http://git-wip-us.apache.org/repos/asf/ambari/blob/7cf17e44/ambari-web/app/views/main/host.js -- diff --git a/ambari-web/app/views/main/host.js b/ambari-web/app/views/main/host.js index f63870f..7ff4c69 100644 --- a/ambari-web/app/views/main/host.js +++ b/ambari-web/app/views/main/host.js @@ -181,7 +181,7 @@ App.MainHostView = App.TableView.extend(App.TableServerViewMixin, { */ willInsertElement: function () { if (!this.get('controller.showFilterConditionsFirstLoad')) { - var didClearedSomething = this.clearFilterCondition(); + var didClearedSomething = this.clearFilterConditionsFromLocalStorage(); this.set('controller.filterChangeHappened', didClearedSomething); } this._super(); @@ -1174,5 +1174,22 @@ App.MainHostView = App.TableView.extend(App.TableServerViewMixin, { */ colPropAssoc: function () { return this.get('controller.colPropAssoc'); - }.property('controller.colPropAssoc') + }.property('controller.colPropAssoc'), + + /** + * Run clearFilter in the each child filterView + */ + clearFilters: function() { +// clean filters stored in-memory and local storage +this.set('filterConditions', []); +this.clearFilterConditionsFromLocalStorage(); +// clean UI +this.get('_childViews').forEach(function(childView) { + if (childView['clearFilter']) { +childView.clearFilter(); + } +}); +// force refresh +this.refresh(); + } }); http://git-wip-us.apache.org/repos/asf/ambari/blob/7cf17e44/ambari-web/test/views/main/alert_definitions_view_test.js -- diff --git a/ambari-web/test/views/main/alert_definitions_view_test.js b/ambari-web/test/views/main/alert_definitions_view_test.js index b9796d1..65dc204 100644 --- a/ambari-web/test/views/main/alert_definitions_view_test.js +++ b/ambari-web/test/views/main/alert_definitions_view_test.js @@ -40,26 +40,26 @@ describe('App.MainAlertDefinitionsView', function () { describe('#willInsertElement', function () { beforeEach(function(){ - sinon.stub(view, 'clearFilterCondition', Em.K); + sinon.stub(view, 'clearFilterConditionsFromLocalStorage', Em.K); sinon.stub(view, 'clearStartIndex', Em.K);
ambari git commit: AMBARI-12959 FE: Server overloaded with POST calls after changing config group. (atkach)
Repository: ambari Updated Branches: refs/heads/trunk ac06e6d83 -> f917a88f8 AMBARI-12959 FE: Server overloaded with POST calls after changing config group. (atkach) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/f917a88f Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/f917a88f Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/f917a88f Branch: refs/heads/trunk Commit: f917a88f8a9f7f5a5918e51a0bd91ff1ef0679ea Parents: ac06e6d Author: Andrii TkachAuthored: Wed Sep 2 14:07:42 2015 +0300 Committer: Andrii Tkach Committed: Wed Sep 2 14:07:42 2015 +0300 -- .../controllers/main/service/info/configs.js| 4 +--- .../widgets/slider_config_widget_view.js| 21 +--- 2 files changed, 19 insertions(+), 6 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/f917a88f/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 b899252..eb06a8a 100644 --- a/ambari-web/app/controllers/main/service/info/configs.js +++ b/ambari-web/app/controllers/main/service/info/configs.js @@ -568,9 +568,7 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.ConfigsLoader, A this.setVisibilityForRangerProperties(selectedService); } this._onLoadComplete(); -this.get('configGroups').forEach(function (configGroup) { - this.getRecommendationsForDependencies(null, true, Em.K, configGroup); -}, this); +this.getRecommendationsForDependencies(null, true, Em.K, this.get('selectedConfigGroup')); App.loadTimer.finish('Service Configs Page'); }, http://git-wip-us.apache.org/repos/asf/ambari/blob/f917a88f/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js -- diff --git a/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js b/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js index 8f42336..1e591c0 100644 --- a/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js +++ b/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js @@ -106,12 +106,27 @@ App.SliderConfigWidgetView = App.ConfigWidgetView.extend({ * config.stackConfigProperty.valueAttributes.{group.name}.maximum * @param {String} attribute - name of attribute, for current moment * can be ["maximum","minimum","increment_step"] but allows to use other it there will be available - * @returns {*} + * @returns {string} */ getValueAttributeByGroup: function(attribute) { +var parseFunction = this.get('parseFunction'); +var configValue = this.get('config.value'); var defaultGroupAttr = this.get('config.stackConfigProperty.valueAttributes'); -var groupAttr = this.get('configGroup') && this.get('config.stackConfigProperty.valueAttributes')[this.get('configGroup.name')]; -return (groupAttr && !Em.isNone(groupAttr[attribute])) ? groupAttr[attribute] : defaultGroupAttr[attribute]; +var groupAttr = this.get('configGroup') && defaultGroupAttr[this.get('configGroup.name')]; +var boundary = (groupAttr && !Em.isNone(groupAttr[attribute])) ? groupAttr[attribute] : defaultGroupAttr[attribute]; + +if (!this.get('referToSelectedGroup')) { + if (attribute === 'minimum') { +if (parseFunction(configValue) < parseFunction(boundary)) { + return configValue; +} + } else if (attribute === 'maximum') { +if (parseFunction(configValue) > parseFunction(boundary)) { + return configValue; +} + } +} +return boundary; }, /** * step transformed form config units to widget units
ambari git commit: AMBARI-12975. HBase metrics on Heatmaps are not available from RegionServer component.(vbrodetskyi)
Repository: ambari Updated Branches: refs/heads/branch-2.1 bb1473df4 -> fdd3029e7 AMBARI-12975. HBase metrics on Heatmaps are not available from RegionServer component.(vbrodetskyi) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/fdd3029e Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/fdd3029e Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/fdd3029e Branch: refs/heads/branch-2.1 Commit: fdd3029e757c92552f5c6ea732c011e69473ec48 Parents: bb1473d Author: Vitaly BrodetskyiAuthored: Wed Sep 2 16:31:28 2015 +0300 Committer: Vitaly Brodetskyi Committed: Wed Sep 2 16:31:28 2015 +0300 -- .../stacks/HDP/2.3/services/HBASE/metrics.json | 70 +++- 1 file changed, 10 insertions(+), 60 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/fdd3029e/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json -- diff --git a/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json b/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json index 7f9cc16..e591970 100644 --- a/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json +++ b/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json @@ -222,7 +222,7 @@ }, "metrics/hbase/regionserver/writeRequestsCount": { "metric": "regionserver.Server.writeRequestCount", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/getRequestLatency_min": { @@ -277,7 +277,7 @@ }, "metrics/hbase/regionserver/readRequestsCount": { "metric": "regionserver.Server.readRequestCount", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/putRequestLatency_min": { @@ -463,7 +463,7 @@ }, "metrics/hbase/regionserver/compactionQueueSize": { "metric": "regionserver.Server.compactionQueueLength", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/flushTime_num_ops": { @@ -523,7 +523,7 @@ }, "metrics/hbase/regionserver/regions": { "metric": "regionserver.Server.regionCount", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/blockCacheFree": { @@ -659,7 +659,7 @@ }, "metrics/hbase/regionserver/memstoreSize": { "metric": "regionserver.Server.memStoreSize", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/deleteRequestLatency_75th_percentile": { @@ -1470,11 +1470,6 @@ "pointInTime": true, "temporal": false }, -"metrics/hbase/regionserver/compactionQueueSize": { - "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.compactionQueueLength", - "pointInTime": true, - "temporal": false -}, "metrics/hbase/regionserver/putRequestLatency_median": { "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.Mutate_median", "pointInTime": true, @@ -1500,11 +1495,6 @@ "pointInTime": true, "temporal": false }, -"metrics/hbase/regionserver/readRequestsCount": { - "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.readRequestCount", - "pointInTime": true, - "temporal": false -}, "metrics/hbase/regionserver/putRequestLatency_min": { "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.Mutate_min", "pointInTime": true, @@ -1555,11 +1545,6 @@ "pointInTime": true, "temporal": false }, -"metrics/hbase/regionserver/writeRequestsCount": { - "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.writeRequestCount", - "pointInTime": true, - "temporal": false -}, "metrics/hbase/regionserver/getRequestLatency_median": { "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.Get_median", "pointInTime": true, @@
ambari git commit: AMBARI-12976. DDL create script for SQLA is outdated. (mpapirkovskyy)
Repository: ambari Updated Branches: refs/heads/branch-2.1 fdd3029e7 -> 516405589 AMBARI-12976. DDL create script for SQLA is outdated. (mpapirkovskyy) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/51640558 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/51640558 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/51640558 Branch: refs/heads/branch-2.1 Commit: 5164055896a553caf03f16b92c6d9c4073be9511 Parents: fdd3029 Author: Myroslav PapirkovskyyAuthored: Wed Sep 2 16:17:29 2015 +0300 Committer: Myroslav Papirkovskyy Committed: Wed Sep 2 16:32:04 2015 +0300 -- .../src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/51640558/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql -- diff --git a/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql b/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql index 9f21160..b6d6212 100644 --- a/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql +++ b/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql @@ -109,6 +109,7 @@ CREATE TABLE hostcomponentdesiredstate ( ); CREATE TABLE hostcomponentstate ( + id NUMERIC(19) NOT NULL, cluster_id NUMERIC(19) NOT NULL, component_name VARCHAR(255) NOT NULL, version VARCHAR(32) NOT NULL DEFAULT 'UNKNOWN', @@ -118,9 +119,11 @@ CREATE TABLE hostcomponentstate ( service_name VARCHAR(255) NOT NULL, upgrade_state VARCHAR(32) NOT NULL DEFAULT 'NONE', security_state VARCHAR(32) NOT NULL DEFAULT 'UNSECURED', - PRIMARY KEY (cluster_id, component_name, host_id, service_name) + PRIMARY KEY (id) ); +CREATE INDEX idx_host_component_state on hostcomponentstate(host_id, component_name, service_name, cluster_id); + CREATE TABLE hosts ( host_id NUMERIC(19) NOT NULL, host_name VARCHAR(255) NOT NULL, @@ -936,6 +939,7 @@ INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('topology_lo INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('topology_logical_task_id_seq', 0); INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('topology_request_id_seq', 0); INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('topology_host_group_id_seq', 0); +INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('hostcomponentstate_id_seq', 0); insert into adminresourcetype (resource_type_id, resource_type_name) select 1, 'AMBARI'
ambari git commit: AMBARI-12975. HBase metrics on Heatmaps are not available from RegionServer component.(vbrodetskyi)
Repository: ambari Updated Branches: refs/heads/trunk 32d485ae1 -> 133535e6e AMBARI-12975. HBase metrics on Heatmaps are not available from RegionServer component.(vbrodetskyi) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/133535e6 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/133535e6 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/133535e6 Branch: refs/heads/trunk Commit: 133535e6efdba81d8c9c8f38fb8c5253b294901f Parents: 32d485a Author: Vitaly BrodetskyiAuthored: Wed Sep 2 16:32:24 2015 +0300 Committer: Vitaly Brodetskyi Committed: Wed Sep 2 16:33:00 2015 +0300 -- .../stacks/HDP/2.3/services/HBASE/metrics.json | 70 +++- 1 file changed, 10 insertions(+), 60 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/133535e6/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json -- diff --git a/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json b/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json index 7f9cc16..e591970 100644 --- a/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json +++ b/ambari-server/src/main/resources/stacks/HDP/2.3/services/HBASE/metrics.json @@ -222,7 +222,7 @@ }, "metrics/hbase/regionserver/writeRequestsCount": { "metric": "regionserver.Server.writeRequestCount", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/getRequestLatency_min": { @@ -277,7 +277,7 @@ }, "metrics/hbase/regionserver/readRequestsCount": { "metric": "regionserver.Server.readRequestCount", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/putRequestLatency_min": { @@ -463,7 +463,7 @@ }, "metrics/hbase/regionserver/compactionQueueSize": { "metric": "regionserver.Server.compactionQueueLength", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/flushTime_num_ops": { @@ -523,7 +523,7 @@ }, "metrics/hbase/regionserver/regions": { "metric": "regionserver.Server.regionCount", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/blockCacheFree": { @@ -659,7 +659,7 @@ }, "metrics/hbase/regionserver/memstoreSize": { "metric": "regionserver.Server.memStoreSize", - "pointInTime": false, + "pointInTime": true, "temporal": true }, "metrics/hbase/regionserver/deleteRequestLatency_75th_percentile": { @@ -1470,11 +1470,6 @@ "pointInTime": true, "temporal": false }, -"metrics/hbase/regionserver/compactionQueueSize": { - "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.compactionQueueLength", - "pointInTime": true, - "temporal": false -}, "metrics/hbase/regionserver/putRequestLatency_median": { "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.Mutate_median", "pointInTime": true, @@ -1500,11 +1495,6 @@ "pointInTime": true, "temporal": false }, -"metrics/hbase/regionserver/readRequestsCount": { - "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.readRequestCount", - "pointInTime": true, - "temporal": false -}, "metrics/hbase/regionserver/putRequestLatency_min": { "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.Mutate_min", "pointInTime": true, @@ -1555,11 +1545,6 @@ "pointInTime": true, "temporal": false }, -"metrics/hbase/regionserver/writeRequestsCount": { - "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.writeRequestCount", - "pointInTime": true, - "temporal": false -}, "metrics/hbase/regionserver/getRequestLatency_median": { "metric": "Hadoop:service=HBase,name=RegionServer,sub=Server.Get_median", "pointInTime": true, @@ -1597,11
ambari git commit: AMBARI-12976. DDL create script for SQLA is outdated. (mpapirkovskyy)
Repository: ambari Updated Branches: refs/heads/trunk c93d2b932 -> 32d485ae1 AMBARI-12976. DDL create script for SQLA is outdated. (mpapirkovskyy) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/32d485ae Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/32d485ae Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/32d485ae Branch: refs/heads/trunk Commit: 32d485ae169da97272c555eea9a2b3c774bd0a51 Parents: c93d2b9 Author: Myroslav PapirkovskyyAuthored: Wed Sep 2 16:17:29 2015 +0300 Committer: Myroslav Papirkovskyy Committed: Wed Sep 2 16:17:29 2015 +0300 -- .../src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/32d485ae/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql -- diff --git a/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql b/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql index 8abd6ab..97b5e11 100644 --- a/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql +++ b/ambari-server/src/main/resources/Ambari-DDL-SQLAnywhere-CREATE.sql @@ -109,6 +109,7 @@ CREATE TABLE hostcomponentdesiredstate ( ); CREATE TABLE hostcomponentstate ( + id NUMERIC(19) NOT NULL, cluster_id NUMERIC(19) NOT NULL, component_name VARCHAR(255) NOT NULL, version VARCHAR(32) NOT NULL DEFAULT 'UNKNOWN', @@ -118,9 +119,11 @@ CREATE TABLE hostcomponentstate ( service_name VARCHAR(255) NOT NULL, upgrade_state VARCHAR(32) NOT NULL DEFAULT 'NONE', security_state VARCHAR(32) NOT NULL DEFAULT 'UNSECURED', - PRIMARY KEY (cluster_id, component_name, host_id, service_name) + PRIMARY KEY (id) ); +CREATE INDEX idx_host_component_state on hostcomponentstate(host_id, component_name, service_name, cluster_id); + CREATE TABLE hosts ( host_id NUMERIC(19) NOT NULL, host_name VARCHAR(255) NOT NULL, @@ -936,6 +939,7 @@ INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('topology_lo INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('topology_logical_task_id_seq', 0); INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('topology_request_id_seq', 0); INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('topology_host_group_id_seq', 0); +INSERT INTO ambari_sequences(sequence_name, sequence_value) values ('hostcomponentstate_id_seq', 0); insert into adminresourcetype (resource_type_id, resource_type_name) select 1, 'AMBARI'
ambari git commit: AMBARI-12940. SQLA: add property validation check for BP oozie/hive, about SQLA should be available only for stack 2.3+.(vbrodetskyi)
Repository: ambari Updated Branches: refs/heads/branch-2.1 30072598b -> 0a624f662 AMBARI-12940. SQLA: add property validation check for BP oozie/hive, about SQLA should be available only for stack 2.3+.(vbrodetskyi) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/0a624f66 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/0a624f66 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/0a624f66 Branch: refs/heads/branch-2.1 Commit: 0a624f66219160d86ee7bd30a117963c22c2bfc7 Parents: 3007259 Author: Vitaly BrodetskyiAuthored: Wed Sep 2 13:47:25 2015 +0300 Committer: Vitaly Brodetskyi Committed: Wed Sep 2 13:47:25 2015 +0300 -- .../server/topology/BlueprintValidatorImpl.java | 25 ++- .../topology/BlueprintValidatorImplTest.java| 46 2 files changed, 70 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/0a624f66/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java b/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java index 70d1907..1b3a910 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java @@ -21,6 +21,7 @@ package org.apache.ambari.server.topology; import org.apache.ambari.server.controller.internal.Stack; import org.apache.ambari.server.state.AutoDeployInfo; import org.apache.ambari.server.state.DependencyInfo; +import org.apache.ambari.server.utils.VersionUtils; import java.util.Collection; import java.util.Collections; @@ -94,11 +95,33 @@ public class BlueprintValidatorImpl implements BlueprintValidator { Map hiveEnvConfig = clusterConfigurations.get("hive-env"); if (hiveEnvConfig != null && !hiveEnvConfig.isEmpty() && hiveEnvConfig.get("hive_database") != null && hiveEnvConfig.get("hive_database").startsWith("Existing")) { -throw new IllegalArgumentException("Incorrect configuration: MYSQL_SERVER component is available but hive" + +throw new InvalidTopologyException("Incorrect configuration: MYSQL_SERVER component is available but hive" + " using existing db!"); } } +if (component.equals("HIVE_METASTORE")) { + Map hiveEnvConfig = clusterConfigurations.get("hive-env"); + if (hiveEnvConfig != null && !hiveEnvConfig.isEmpty() && hiveEnvConfig.get("hive_database") !=null + && hiveEnvConfig.get("hive_database").equals("Existing SQLA Database") + && VersionUtils.compareVersions(stack.getVersion(), "2.3.0.0") < 0 + && stack.getName().equalsIgnoreCase("HDP")) { +throw new InvalidTopologyException("Incorrect configuration: SQLA db is available only for stack HDP-2.3+ " + +"and repo version 2.3.2+!"); + } +} + +if (component.equals("OOZIE_SERVER")) { + Map oozieEnvConfig = clusterConfigurations.get("oozie-env"); + if (oozieEnvConfig != null && !oozieEnvConfig.isEmpty() && oozieEnvConfig.get("oozie_database") !=null + && oozieEnvConfig.get("oozie_database").equals("Existing SQLA Database") + && VersionUtils.compareVersions(stack.getVersion(), "2.3.0.0") < 0 + && stack.getName().equalsIgnoreCase("HDP")) { +throw new InvalidTopologyException("Incorrect configuration: SQLA db is available only for stack HDP-2.3+ " + +"and repo version 2.3.2+!"); + } +} + //for now, AMBARI is not recognized as a service in Stacks if (! component.equals("AMBARI_SERVER")) { String serviceName = stack.getServiceForComponent(component); http://git-wip-us.apache.org/repos/asf/ambari/blob/0a624f66/ambari-server/src/test/java/org/apache/ambari/server/topology/BlueprintValidatorImplTest.java -- diff --git a/ambari-server/src/test/java/org/apache/ambari/server/topology/BlueprintValidatorImplTest.java b/ambari-server/src/test/java/org/apache/ambari/server/topology/BlueprintValidatorImplTest.java index 0b1573b..cc2b189 100644 --- a/ambari-server/src/test/java/org/apache/ambari/server/topology/BlueprintValidatorImplTest.java +++
ambari git commit: AMBARI-12940. SQLA: add property validation check for BP oozie/hive, about SQLA should be available only for stack 2.3+.(vbrodetskyi)
Repository: ambari Updated Branches: refs/heads/trunk 205e45d53 -> ac06e6d83 AMBARI-12940. SQLA: add property validation check for BP oozie/hive, about SQLA should be available only for stack 2.3+.(vbrodetskyi) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/ac06e6d8 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/ac06e6d8 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/ac06e6d8 Branch: refs/heads/trunk Commit: ac06e6d839009d802357a5fcdf45dd493d782906 Parents: 205e45d Author: Vitaly BrodetskyiAuthored: Wed Sep 2 13:48:25 2015 +0300 Committer: Vitaly Brodetskyi Committed: Wed Sep 2 13:48:25 2015 +0300 -- .../server/topology/BlueprintValidatorImpl.java | 25 ++- .../topology/BlueprintValidatorImplTest.java| 46 2 files changed, 70 insertions(+), 1 deletion(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/ac06e6d8/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java -- diff --git a/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java b/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java index 70d1907..1b3a910 100644 --- a/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java +++ b/ambari-server/src/main/java/org/apache/ambari/server/topology/BlueprintValidatorImpl.java @@ -21,6 +21,7 @@ package org.apache.ambari.server.topology; import org.apache.ambari.server.controller.internal.Stack; import org.apache.ambari.server.state.AutoDeployInfo; import org.apache.ambari.server.state.DependencyInfo; +import org.apache.ambari.server.utils.VersionUtils; import java.util.Collection; import java.util.Collections; @@ -94,11 +95,33 @@ public class BlueprintValidatorImpl implements BlueprintValidator { Map hiveEnvConfig = clusterConfigurations.get("hive-env"); if (hiveEnvConfig != null && !hiveEnvConfig.isEmpty() && hiveEnvConfig.get("hive_database") != null && hiveEnvConfig.get("hive_database").startsWith("Existing")) { -throw new IllegalArgumentException("Incorrect configuration: MYSQL_SERVER component is available but hive" + +throw new InvalidTopologyException("Incorrect configuration: MYSQL_SERVER component is available but hive" + " using existing db!"); } } +if (component.equals("HIVE_METASTORE")) { + Map hiveEnvConfig = clusterConfigurations.get("hive-env"); + if (hiveEnvConfig != null && !hiveEnvConfig.isEmpty() && hiveEnvConfig.get("hive_database") !=null + && hiveEnvConfig.get("hive_database").equals("Existing SQLA Database") + && VersionUtils.compareVersions(stack.getVersion(), "2.3.0.0") < 0 + && stack.getName().equalsIgnoreCase("HDP")) { +throw new InvalidTopologyException("Incorrect configuration: SQLA db is available only for stack HDP-2.3+ " + +"and repo version 2.3.2+!"); + } +} + +if (component.equals("OOZIE_SERVER")) { + Map oozieEnvConfig = clusterConfigurations.get("oozie-env"); + if (oozieEnvConfig != null && !oozieEnvConfig.isEmpty() && oozieEnvConfig.get("oozie_database") !=null + && oozieEnvConfig.get("oozie_database").equals("Existing SQLA Database") + && VersionUtils.compareVersions(stack.getVersion(), "2.3.0.0") < 0 + && stack.getName().equalsIgnoreCase("HDP")) { +throw new InvalidTopologyException("Incorrect configuration: SQLA db is available only for stack HDP-2.3+ " + +"and repo version 2.3.2+!"); + } +} + //for now, AMBARI is not recognized as a service in Stacks if (! component.equals("AMBARI_SERVER")) { String serviceName = stack.getServiceForComponent(component); http://git-wip-us.apache.org/repos/asf/ambari/blob/ac06e6d8/ambari-server/src/test/java/org/apache/ambari/server/topology/BlueprintValidatorImplTest.java -- diff --git a/ambari-server/src/test/java/org/apache/ambari/server/topology/BlueprintValidatorImplTest.java b/ambari-server/src/test/java/org/apache/ambari/server/topology/BlueprintValidatorImplTest.java index 0b1573b..cc2b189 100644 --- a/ambari-server/src/test/java/org/apache/ambari/server/topology/BlueprintValidatorImplTest.java +++
ambari git commit: AMBARI-12959 FE: Server overloaded with POST calls after changing config group. (atkach)
Repository: ambari Updated Branches: refs/heads/branch-2.1 0a624f662 -> 56885a593 AMBARI-12959 FE: Server overloaded with POST calls after changing config group. (atkach) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/56885a59 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/56885a59 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/56885a59 Branch: refs/heads/branch-2.1 Commit: 56885a5934be6f95b5789ecd6349be2abc8fb7f2 Parents: 0a624f6 Author: Andrii TkachAuthored: Tue Sep 1 16:14:07 2015 +0300 Committer: Andrii Tkach Committed: Wed Sep 2 14:03:23 2015 +0300 -- .../controllers/main/service/info/configs.js| 4 +--- .../widgets/slider_config_widget_view.js| 21 +--- 2 files changed, 19 insertions(+), 6 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/56885a59/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 b899252..eb06a8a 100644 --- a/ambari-web/app/controllers/main/service/info/configs.js +++ b/ambari-web/app/controllers/main/service/info/configs.js @@ -568,9 +568,7 @@ App.MainServiceInfoConfigsController = Em.Controller.extend(App.ConfigsLoader, A this.setVisibilityForRangerProperties(selectedService); } this._onLoadComplete(); -this.get('configGroups').forEach(function (configGroup) { - this.getRecommendationsForDependencies(null, true, Em.K, configGroup); -}, this); +this.getRecommendationsForDependencies(null, true, Em.K, this.get('selectedConfigGroup')); App.loadTimer.finish('Service Configs Page'); }, http://git-wip-us.apache.org/repos/asf/ambari/blob/56885a59/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js -- diff --git a/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js b/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js index 8f42336..1e591c0 100644 --- a/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js +++ b/ambari-web/app/views/common/configs/widgets/slider_config_widget_view.js @@ -106,12 +106,27 @@ App.SliderConfigWidgetView = App.ConfigWidgetView.extend({ * config.stackConfigProperty.valueAttributes.{group.name}.maximum * @param {String} attribute - name of attribute, for current moment * can be ["maximum","minimum","increment_step"] but allows to use other it there will be available - * @returns {*} + * @returns {string} */ getValueAttributeByGroup: function(attribute) { +var parseFunction = this.get('parseFunction'); +var configValue = this.get('config.value'); var defaultGroupAttr = this.get('config.stackConfigProperty.valueAttributes'); -var groupAttr = this.get('configGroup') && this.get('config.stackConfigProperty.valueAttributes')[this.get('configGroup.name')]; -return (groupAttr && !Em.isNone(groupAttr[attribute])) ? groupAttr[attribute] : defaultGroupAttr[attribute]; +var groupAttr = this.get('configGroup') && defaultGroupAttr[this.get('configGroup.name')]; +var boundary = (groupAttr && !Em.isNone(groupAttr[attribute])) ? groupAttr[attribute] : defaultGroupAttr[attribute]; + +if (!this.get('referToSelectedGroup')) { + if (attribute === 'minimum') { +if (parseFunction(configValue) < parseFunction(boundary)) { + return configValue; +} + } else if (attribute === 'maximum') { +if (parseFunction(configValue) > parseFunction(boundary)) { + return configValue; +} + } +} +return boundary; }, /** * step transformed form config units to widget units
ambari git commit: AMBARI-12973 Web Client Should Warn On Host Version Mismatch For Maintenance Mode. (ababiichuk)
Repository: ambari Updated Branches: refs/heads/trunk f917a88f8 -> c93d2b932 AMBARI-12973 Web Client Should Warn On Host Version Mismatch For Maintenance Mode. (ababiichuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/c93d2b93 Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/c93d2b93 Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/c93d2b93 Branch: refs/heads/trunk Commit: c93d2b932e78bc24c12a615ed2037e6ad186a50a Parents: f917a88 Author: aBabiichukAuthored: Wed Sep 2 15:40:59 2015 +0300 Committer: aBabiichuk Committed: Wed Sep 2 15:43:56 2015 +0300 -- ambari-web/app/controllers/main/host/details.js | 14 ++--- ambari-web/app/messages.js | 2 ++ ambari-web/app/models/stack_version/version.js | 6 +- ambari-web/app/views/main/host.js | 21 +++- 4 files changed, 38 insertions(+), 5 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/c93d2b93/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 0d309ff..7b8e6a9 100644 --- a/ambari-web/app/controllers/main/host/details.js +++ b/ambari-web/app/controllers/main/host/details.js @@ -1817,11 +1817,19 @@ App.MainHostDetailsController = Em.Controller.extend({ var state = context.active ? 'ON' : 'OFF'; var self = this; var message = Em.I18n.t('hosts.host.details.for.postfix').format(context.label); +var popupInfo = Em.I18n.t('hosts.passiveMode.popup').format(context.active ? 'On' : 'Off', this.get('content.hostName')); +if (state === 'OFF') { + var hostVersion = this.get('content.stackVersions') && this.get('content.stackVersions').findProperty('isCurrent').get('repoVersion'), +currentVersion = App.StackVersion.find().findProperty('isCurrent'), +clusterVersion = currentVersion && currentVersion.get('repositoryVersion.repositoryVersion'); + if (hostVersion !== clusterVersion) { +var msg = Em.I18n.t("hosts.passiveMode.popup.version.mismatch").format(this.get('content.hostName'), clusterVersion); +popupInfo += '' + msg + ''; + } +} return App.showConfirmationPopup(function () { self.hostPassiveModeRequest(state, message); - }, - Em.I18n.t('hosts.passiveMode.popup').format(context.active ? 'On' : 'Off', this.get('content.hostName')) -); + }, popupInfo); }, /** http://git-wip-us.apache.org/repos/asf/ambari/blob/c93d2b93/ambari-web/app/messages.js -- diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js index bb42389..7912937 100644 --- a/ambari-web/app/messages.js +++ b/ambari-web/app/messages.js @@ -2283,6 +2283,8 @@ Em.I18n.translations = { 'hosts.add.exit.body':'Do you really want to exit Add Host Wizard?', 'hosts.assignRack':'Assign Rack', 'hosts.passiveMode.popup':'Are you sure you want to Turn {0} Maintenance Mode for {1}?', + 'hosts.passiveMode.popup.version.mismatch': '{0} has components from a stack which is not current. Before bringing this host out of maintenance mode, it is recommended that you upgrade its components to {1}', + 'hosts.passiveMode.popup.version.mismatch.multiple': 'Some hosts have components from a stack which is not current. Before bringing these hosts out of maintenance mode, it is recommended that you upgrade their components to {0}', 'charts.horizon.chart.showText':'show', 'charts.horizon.chart.hideText':'hide', http://git-wip-us.apache.org/repos/asf/ambari/blob/c93d2b93/ambari-web/app/models/stack_version/version.js -- diff --git a/ambari-web/app/models/stack_version/version.js b/ambari-web/app/models/stack_version/version.js index fdc8755..7fd4134 100644 --- a/ambari-web/app/models/stack_version/version.js +++ b/ambari-web/app/models/stack_version/version.js @@ -47,7 +47,11 @@ App.StackVersion = DS.Model.extend({ noInitHosts: function() { return this.get('notInstalledHosts.length') == 0; - }.property('notInstalledHosts.length') + }.property('notInstalledHosts.length'), + + isCurrent: function() { +return this.get('state') === 'CURRENT'; + }.property('state') }); App.StackVersion.FIXTURES = []; http://git-wip-us.apache.org/repos/asf/ambari/blob/c93d2b93/ambari-web/app/views/main/host.js -- diff --git a/ambari-web/app/views/main/host.js b/ambari-web/app/views/main/host.js index a0f1a0c..f63870f
ambari git commit: AMBARI-12973 Web Client Should Warn On Host Version Mismatch For Maintenance Mode. (ababiichuk)
Repository: ambari Updated Branches: refs/heads/branch-2.1 56885a593 -> bb1473df4 AMBARI-12973 Web Client Should Warn On Host Version Mismatch For Maintenance Mode. (ababiichuk) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/bb1473df Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/bb1473df Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/bb1473df Branch: refs/heads/branch-2.1 Commit: bb1473df49174838b48331a601a1cfd4a1255407 Parents: 56885a5 Author: aBabiichukAuthored: Wed Sep 2 15:40:59 2015 +0300 Committer: aBabiichuk Committed: Wed Sep 2 15:40:59 2015 +0300 -- ambari-web/app/controllers/main/host/details.js | 14 ++--- ambari-web/app/messages.js | 2 ++ ambari-web/app/models/stack_version/version.js | 6 +- ambari-web/app/views/main/host.js | 21 +++- 4 files changed, 38 insertions(+), 5 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/bb1473df/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 f3e1489..3cc4de7 100644 --- a/ambari-web/app/controllers/main/host/details.js +++ b/ambari-web/app/controllers/main/host/details.js @@ -1826,11 +1826,19 @@ App.MainHostDetailsController = Em.Controller.extend({ var state = context.active ? 'ON' : 'OFF'; var self = this; var message = Em.I18n.t('hosts.host.details.for.postfix').format(context.label); +var popupInfo = Em.I18n.t('hosts.passiveMode.popup').format(context.active ? 'On' : 'Off', this.get('content.hostName')); +if (state === 'OFF') { + var hostVersion = this.get('content.stackVersions') && this.get('content.stackVersions').findProperty('isCurrent').get('repoVersion'), +currentVersion = App.StackVersion.find().findProperty('isCurrent'), +clusterVersion = currentVersion && currentVersion.get('repositoryVersion.repositoryVersion'); + if (hostVersion !== clusterVersion) { +var msg = Em.I18n.t("hosts.passiveMode.popup.version.mismatch").format(this.get('content.hostName'), clusterVersion); +popupInfo += '' + msg + ''; + } +} return App.showConfirmationPopup(function () { self.hostPassiveModeRequest(state, message); - }, - Em.I18n.t('hosts.passiveMode.popup').format(context.active ? 'On' : 'Off', this.get('content.hostName')) -); + }, popupInfo); }, /** http://git-wip-us.apache.org/repos/asf/ambari/blob/bb1473df/ambari-web/app/messages.js -- diff --git a/ambari-web/app/messages.js b/ambari-web/app/messages.js index 35f72c7..119b1db 100644 --- a/ambari-web/app/messages.js +++ b/ambari-web/app/messages.js @@ -2308,6 +2308,8 @@ Em.I18n.translations = { 'hosts.add.exit.body':'Do you really want to exit Add Host Wizard?', 'hosts.assignRack':'Assign Rack', 'hosts.passiveMode.popup':'Are you sure you want to Turn {0} Maintenance Mode for {1}?', + 'hosts.passiveMode.popup.version.mismatch': '{0} has components from a stack which is not current. Before bringing this host out of maintenance mode, it is recommended that you upgrade its components to {1}', + 'hosts.passiveMode.popup.version.mismatch.multiple': 'Some hosts have components from a stack which is not current. Before bringing these hosts out of maintenance mode, it is recommended that you upgrade their components to {0}', 'charts.horizon.chart.showText':'show', 'charts.horizon.chart.hideText':'hide', http://git-wip-us.apache.org/repos/asf/ambari/blob/bb1473df/ambari-web/app/models/stack_version/version.js -- diff --git a/ambari-web/app/models/stack_version/version.js b/ambari-web/app/models/stack_version/version.js index fdc8755..7fd4134 100644 --- a/ambari-web/app/models/stack_version/version.js +++ b/ambari-web/app/models/stack_version/version.js @@ -47,7 +47,11 @@ App.StackVersion = DS.Model.extend({ noInitHosts: function() { return this.get('notInstalledHosts.length') == 0; - }.property('notInstalledHosts.length') + }.property('notInstalledHosts.length'), + + isCurrent: function() { +return this.get('state') === 'CURRENT'; + }.property('state') }); App.StackVersion.FIXTURES = []; http://git-wip-us.apache.org/repos/asf/ambari/blob/bb1473df/ambari-web/app/views/main/host.js -- diff --git a/ambari-web/app/views/main/host.js b/ambari-web/app/views/main/host.js index
ambari git commit: AMBARI-12581. Host check/clean-up logic should clean up new packages and folder names (dlysnichenko)
Repository: ambari Updated Branches: refs/heads/branch-2.1 516405589 -> 3e9e182d6 AMBARI-12581. Host check/clean-up logic should clean up new packages and folder names (dlysnichenko) Project: http://git-wip-us.apache.org/repos/asf/ambari/repo Commit: http://git-wip-us.apache.org/repos/asf/ambari/commit/3e9e182d Tree: http://git-wip-us.apache.org/repos/asf/ambari/tree/3e9e182d Diff: http://git-wip-us.apache.org/repos/asf/ambari/diff/3e9e182d Branch: refs/heads/branch-2.1 Commit: 3e9e182d6acdd48402e80529c384357125a3e406 Parents: 5164055 Author: Lisnichenko DmitroAuthored: Wed Sep 2 17:48:35 2015 +0300 Committer: Lisnichenko Dmitro Committed: Wed Sep 2 17:48:35 2015 +0300 -- .../python/ambari_agent/HostCheckReportFileHandler.py | 4 +++- ambari-agent/src/main/python/ambari_agent/HostInfo.py | 5 +++-- .../resources/custom_actions/scripts/check_host.py| 14 -- 3 files changed, 14 insertions(+), 9 deletions(-) -- http://git-wip-us.apache.org/repos/asf/ambari/blob/3e9e182d/ambari-agent/src/main/python/ambari_agent/HostCheckReportFileHandler.py -- diff --git a/ambari-agent/src/main/python/ambari_agent/HostCheckReportFileHandler.py b/ambari-agent/src/main/python/ambari_agent/HostCheckReportFileHandler.py index a4b898d..794e427 100644 --- a/ambari-agent/src/main/python/ambari_agent/HostCheckReportFileHandler.py +++ b/ambari-agent/src/main/python/ambari_agent/HostCheckReportFileHandler.py @@ -80,7 +80,7 @@ class HostCheckReportFileHandler: with open(self.hostCheckCustomActionsFilePath, 'wb') as configfile: config.write(configfile) except Exception, err: - logger.error("Can't write host check file at %s :%s " % (self.hostCheckFilePath, err.message)) + logger.error("Can't write host check file at %s :%s " % (self.hostCheckCustomActionsFilePath, err.message)) traceback.print_exc() def writeHostCheckFile(self, hostInfo): @@ -117,6 +117,8 @@ class HostCheckReportFileHandler: items = [] for itemDetail in hostInfo['stackFoldersAndFiles']: items.append(itemDetail['name']) +if os.path.exists('/usr/hdp'): + items.append('/usr/hdp') config.add_section('directories') config.set('directories', 'dir_list', ','.join(items)) http://git-wip-us.apache.org/repos/asf/ambari/blob/3e9e182d/ambari-agent/src/main/python/ambari_agent/HostInfo.py -- diff --git a/ambari-agent/src/main/python/ambari_agent/HostInfo.py b/ambari-agent/src/main/python/ambari_agent/HostInfo.py index b979242..e9d4110 100644 --- a/ambari-agent/src/main/python/ambari_agent/HostInfo.py +++ b/ambari-agent/src/main/python/ambari_agent/HostInfo.py @@ -132,7 +132,7 @@ class HostInfoLinux(HostInfo): "rrdcached", "hcat", "ambari-qa", "sqoop-ambari-qa", "sqoop-ambari_qa", "webhcat", "hadoop-hdfs", "hadoop-yarn", "hadoop-mapreduce", "knox", "yarn", "hive-webhcat", "kafka", "slider", "storm-slider-client", -"ganglia-web" +"ganglia-web", "mahout", "spark", "pig", "phoenix", "ranger", "accumulo" ] @@ -144,7 +144,8 @@ class HostInfoLinux(HostInfo): DEFAULT_USERS = [ "hive", "ambari-qa", "oozie", "hbase", "hcat", "mapred", "hdfs", "zookeeper", "flume", "sqoop", "sqoop2", -"hue", "yarn", "tez", "storm", "falcon", "kafka", "knox" +"hue", "yarn", "tez", "storm", "falcon", "kafka", "knox", "ams", +"hadoop", "spark", "accumulo", "atlas", "mahout", "ranger", "kms" ] # Default set of directories that are checked for existence of files and folders http://git-wip-us.apache.org/repos/asf/ambari/blob/3e9e182d/ambari-server/src/main/resources/custom_actions/scripts/check_host.py -- diff --git a/ambari-server/src/main/resources/custom_actions/scripts/check_host.py b/ambari-server/src/main/resources/custom_actions/scripts/check_host.py index 1e54180..4d3cf76 100644 --- a/ambari-server/src/main/resources/custom_actions/scripts/check_host.py +++ b/ambari-server/src/main/resources/custom_actions/scripts/check_host.py @@ -74,32 +74,34 @@ THP_FILE = "/sys/kernel/mm/redhat_transparent_hugepage/enabled" class CheckHost(Script): # Packages that are used to find repos (then repos are used to find other packages) PACKAGES = [ -"hadoop_2_2_*", "hadoop-2-2-.*", "zookeeper_2_2_*", "zookeeper-2-2-.*", -"hadoop", "zookeeper", "webhcat", "*-manager-server-db", "*-manager-daemons" +"hadoop", "zookeeper", "webhcat", "oozie", "ambari", "*-manager-server-db", +"*-manager-daemons", "mahout", "spark", "falcon", "hbase", "kafka", "knox", +"slider", "sqoop", "storm", "pig",