You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues-all@impala.apache.org by "ASF subversion and git services (JIRA)" <ji...@apache.org> on 2019/06/20 20:44:00 UTC

[jira] [Commented] (IMPALA-8552) impala-shell tests break on deployed clusters if IMPALA_LOCAL_BUILD_VERSION is None

    [ https://issues.apache.org/jira/browse/IMPALA-8552?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16868921#comment-16868921 ] 

ASF subversion and git services commented on IMPALA-8552:
---------------------------------------------------------

Commit 9ecbe7d3dc22d7233e4bf2f91aaab43d0ad4e373 in impala's branch refs/heads/master from Tim Armstrong
[ https://gitbox.apache.org/repos/asf?p=impala.git;h=9ecbe7d ]

IMPALA-8553,IMPALA-8552: fix checks for remote cluster

Apparently IMPALA_REMOTE_URL is not generally used for remote cluster
tests: only --testing_remote_cluster is reliably set. Fix the
is_remote_cluster() implementation to take into account
REMOTE_DATA_LOAD and --testing_remote_cluster in addition to
IMPALA_REMOTE_URL. Consistently use is_remote_cluster() in
other tests instead of checking the pytest flag directly.

There were a few lifecycle headaches with how
ImpalaTestClusterProperties is used:
* common.environ is imported from conftest, which means that
  the top-level code in the file runs *before* pytest
  command-line arguments have been registered and parsed.
* ImpalaTestClusterProperties is used by various code,
  like build_flavor_timeout(), which runs before pytest
  command-line arguments have been parsed.
* ImpalaTestClusterProperties is called from non-pytest
  scripts like start-impala-cluster.py, so the command-line
  arguments are not available.

I dealt with the above challenges by making a few changes
to do the detection later:
* Lazily initializing a singleton ImpalaTestClusterProperties.
  This was not strictly necessary but makes the whole problem
  less sensitive to import order and module dependencies.
* Adding cluster_properties fixture to make ImpalaTestClusterProperties
  available in tests without additional boilerplate.
* Removing the caching of the local/remote build calculation.
  ImpalaTestClusterProperties is instantiated outside of python
  tests, but is_remote_cluster() is only called from python tests,
  so if we check flags in is_remote_cluster() we'll get the
  right results reliably.

As a workaround to unblock remote tests, also assume catalog_v1 if
accessing the web UI fails.

Testing:
Ran core tests against a regular minicluster.

Ran tests against a remote cluster

Change-Id: Ifa6b2a1391f53121d3d7c00c5cf0a57590899ce4
Reviewed-on: http://gerrit.cloudera.org:8080/13386
Reviewed-by: Tim Armstrong <ta...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>


> impala-shell tests break on deployed clusters if IMPALA_LOCAL_BUILD_VERSION is None
> -----------------------------------------------------------------------------------
>
>                 Key: IMPALA-8552
>                 URL: https://issues.apache.org/jira/browse/IMPALA-8552
>             Project: IMPALA
>          Issue Type: Bug
>          Components: Infrastructure
>    Affects Versions: Impala 3.3.0
>            Reporter: David Knupp
>            Assignee: Tim Armstrong
>            Priority: Critical
>
> This is a regression introduced by the commit: https://github.com/apache/impala/commit/b55d905
> *Stacktrace*
> {noformat}
> shell/test_shell_commandline.py:33: in <module>
>     from util import (get_impalad_host_port, assert_var_substitution, run_impala_shell_cmd,
> shell/util.py:42: in <module>
>     IMPALA_HOME, "shell/build", "impala-shell-" + IMPALA_LOCAL_BUILD_VERSION,
> E   TypeError: cannot concatenate 'str' and 'NoneType' objects
> {noformat}



--
This message was sent by Atlassian JIRA
(v7.6.3#76005)

---------------------------------------------------------------------
To unsubscribe, e-mail: issues-all-unsubscribe@impala.apache.org
For additional commands, e-mail: issues-all-help@impala.apache.org