You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@impala.apache.org by ta...@apache.org on 2020/07/21 16:22:08 UTC
[impala] 02/03: IMPALA-9889: Fixed flaky test_runtime_filters on
Kudu table
This is an automated email from the ASF dual-hosted git repository.
tarmstrong pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/impala.git
commit d12ceec23bbb11da171cb54a3370d22a904f1d2a
Author: wzhou-code <wz...@cloudera.com>
AuthorDate: Sat Jul 11 11:43:13 2020 -0700
IMPALA-9889: Fixed flaky test_runtime_filters on Kudu table
Test cases in test_runtime_filters failed occasionally in ASAN
builds due to runtime filters not arriving scan nodes in time.
Query profiles showed that codegen took 2 to 4 minutes for one
fragment when this issue happened. This caused hash join nodes
waiting long time to generate and publish runtime filters, hence
arrival delay on scan nodes. To avoid the delay, turn on
ASYNC_CODEGEN for test_runtime_filters when test runs for slow
build like ASAN, TSAN, UBSAN, etc.
Testing:
- Passed core test for regular debug build and ASAN build.
Change-Id: I94a08e272f0870c04c96563fa614e3416fb5379b
Reviewed-on: http://gerrit.cloudera.org:8080/16191
Reviewed-by: Thomas Tauber-Marshall <tm...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
tests/query_test/test_runtime_filters.py | 23 +++++++++++++++++++++++
1 file changed, 23 insertions(+)
diff --git a/tests/query_test/test_runtime_filters.py b/tests/query_test/test_runtime_filters.py
index f08f948..0048c28 100644
--- a/tests/query_test/test_runtime_filters.py
+++ b/tests/query_test/test_runtime_filters.py
@@ -23,9 +23,11 @@ import time
from beeswaxd.BeeswaxService import QueryState
from tests.common.environ import build_flavor_timeout
+from tests.common.environ import ImpalaTestClusterProperties
from tests.common.impala_cluster import ImpalaCluster
from tests.common.impala_test_suite import ImpalaTestSuite
from tests.common.skip import SkipIfLocal, SkipIfIsilon
+from tests.common.test_dimensions import add_exec_option_dimension
from tests.common.test_vector import ImpalaTestDimension
from tests.verifiers.metric_verifier import MetricVerifier
@@ -33,6 +35,12 @@ from tests.verifiers.metric_verifier import MetricVerifier
# runtime filters don't arrive in time.
WAIT_TIME_MS = build_flavor_timeout(60000, slow_build_timeout=200000)
+# Check whether the Impala under test in slow build. Query option ASYNC_CODEGEN will
+# be enabled when test runs for slow build like ASAN, TSAN, UBSAN, etc. This avoid
+# failures like IMPALA-9889 where the runtime filters don't arrive in time due to
+# the slowness of codegen.
+build_runs_slowly = ImpalaTestClusterProperties.get_instance().runs_slowly()
+
# Some of the queries in runtime_filters consume a lot of memory, leading to
# significant memory reservations in parallel tests.
# Skipping Isilon due to IMPALA-6998. TODO: Remove when there's a holistic revamp of
@@ -59,6 +67,9 @@ class TestRuntimeFilters(ImpalaTestSuite):
cls.ImpalaTestMatrix.add_constraint(
lambda v: v.get_value('table_format').file_format in ['parquet', 'text', 'kudu']
or v.get_value('mt_dop') == 0)
+ # Enable query option ASYNC_CODEGEN for slow build
+ if build_runs_slowly:
+ add_exec_option_dimension(cls, "async_codegen", 1)
def test_basic_filters(self, vector):
new_vector = deepcopy(vector)
@@ -172,6 +183,9 @@ class TestBloomFilters(ImpalaTestSuite):
# Bloom filters are disabled on HBase
cls.ImpalaTestMatrix.add_constraint(
lambda v: v.get_value('table_format').file_format not in ['hbase'])
+ # Enable query option ASYNC_CODEGEN for slow build
+ if build_runs_slowly:
+ add_exec_option_dimension(cls, "async_codegen", 1)
def test_bloom_filters(self, vector):
if 'kudu' in str(vector.get_value('table_format')):
@@ -201,6 +215,9 @@ class TestMinMaxFilters(ImpalaTestSuite):
# Min-max filters are only implemented for Kudu.
cls.ImpalaTestMatrix.add_constraint(
lambda v: v.get_value('table_format').file_format in ['kudu'])
+ # Enable query option ASYNC_CODEGEN for slow build
+ if build_runs_slowly:
+ add_exec_option_dimension(cls, "async_codegen", 1)
def test_min_max_filters(self, vector):
self.execute_query("SET ENABLED_RUNTIME_FILTER_TYPES=MIN_MAX")
@@ -270,6 +287,9 @@ class TestAllRuntimeFilters(ImpalaTestSuite):
# All filters are only implemented for Kudu now.
cls.ImpalaTestMatrix.add_constraint(
lambda v: v.get_value('table_format').file_format in ['kudu'])
+ # Enable query option ASYNC_CODEGEN for slow build
+ if build_runs_slowly:
+ add_exec_option_dimension(cls, "async_codegen", 1)
def test_all_runtime_filters(self, vector):
self.execute_query("SET ENABLED_RUNTIME_FILTER_TYPES=ALL")
@@ -296,6 +316,9 @@ class TestRuntimeRowFilters(ImpalaTestSuite):
# Exercise both mt and non-mt code paths. Some tests assume 3 finstances, so
# tests are not expected to work unmodified with higher mt_dop values.
cls.ImpalaTestMatrix.add_dimension(ImpalaTestDimension('mt_dop', 0, 4))
+ # Enable query option ASYNC_CODEGEN for slow build
+ if build_runs_slowly:
+ add_exec_option_dimension(cls, "async_codegen", 1)
def test_row_filters(self, vector):
new_vector = deepcopy(vector)