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 2019/08/15 00:43:46 UTC
[impala] branch master updated: IMPALA-8856: Deflake
TestKuduHMSIntegration
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
The following commit(s) were added to refs/heads/master by this push:
new d5d3ace IMPALA-8856: Deflake TestKuduHMSIntegration
d5d3ace is described below
commit d5d3ace6c27123f788dc292a651f1df0c8620686
Author: Hao Hao <ha...@cloudera.com>
AuthorDate: Wed Aug 14 11:59:40 2019 -0700
IMPALA-8856: Deflake TestKuduHMSIntegration
Tests for Kudu's integration with the Hive Metastore can be flaky.
Since Kudu depends on the HMS, create/drop table requests can timeout
when creation/deletion in the HMS take more than 10s, and the following
retry will fail as the table has been already created/deleted by the
first request.
This patch increases the timeout of individual Kudu client rpcs to
avoid flakiness cause by such cases.
Change-Id: Ib98f34bb831b9255e35b5ef234abe6ceaf261bfd
Reviewed-on: http://gerrit.cloudera.org:8080/14067
Reviewed-by: Tim Armstrong <ta...@cloudera.com>
Tested-by: Impala Public Jenkins <im...@cloudera.com>
---
tests/custom_cluster/test_kudu.py | 24 +++++++++++++++++++-----
1 file changed, 19 insertions(+), 5 deletions(-)
diff --git a/tests/custom_cluster/test_kudu.py b/tests/custom_cluster/test_kudu.py
index 17ea63a..96c8717 100644
--- a/tests/custom_cluster/test_kudu.py
+++ b/tests/custom_cluster/test_kudu.py
@@ -140,9 +140,12 @@ class TestKuduHMSIntegration(CustomClusterTestSuite, KuduTestSuite):
@pytest.mark.execute_serially
@SkipIfKudu.no_hybrid_clock
+ @CustomClusterTestSuite.with_args(impalad_args="-kudu_client_rpc_timeout_ms=30000")
def test_create_managed_kudu_tables(self, vector, unique_database):
"""Tests the Create table operation when using a kudu table with Kudu's integration
- with the Hive Metastore for managed tables."""
+ with the Hive Metastore for managed tables. Increase timeout of individual Kudu
+ client rpcs to avoid requests fail due to operation delay in the Hive Metastore
+ for managed tables (IMPALA-8856)."""
vector.get_value('exec_option')['kudu_read_mode'] = "READ_AT_SNAPSHOT"
self.run_test_case('QueryTest/kudu_create', vector, use_db=unique_database)
@@ -174,9 +177,12 @@ class TestKuduHMSIntegration(CustomClusterTestSuite, KuduTestSuite):
@pytest.mark.execute_serially
@SkipIfHive3.kudu_hms_notifications_not_supported
+ @CustomClusterTestSuite.with_args(impalad_args="-kudu_client_rpc_timeout_ms=30000")
def test_implicit_managed_table_props(self, cursor, kudu_client, unique_database):
"""Check that table properties added internally for managed table during table
- creation are as expected.
+ creation are as expected. Increase timeout of individual Kudu client rpcs to
+ avoid requests fail due to operation delay in the Hive Metastore for managed
+ tables (IMPALA-8856).
"""
cursor.execute("""CREATE TABLE %s.foo (a INT PRIMARY KEY, s STRING)
PARTITION BY HASH(a) PARTITIONS 3 STORED AS KUDU""" % unique_database)
@@ -197,9 +203,12 @@ class TestKuduHMSIntegration(CustomClusterTestSuite, KuduTestSuite):
@pytest.mark.execute_serially
@SkipIfHive3.kudu_hms_notifications_not_supported
+ @CustomClusterTestSuite.with_args(impalad_args="-kudu_client_rpc_timeout_ms=30000")
def test_drop_non_empty_db(self, unique_cursor, kudu_client):
"""Check that an attempt to drop a database will fail if Kudu tables are present
- and that the tables remain.
+ and that the tables remain. Increase timeout of individual Kudu client rpcs
+ to avoid requests fail due to operation delay in the Hive Metastore for managed
+ tables (IMPALA-8856).
"""
db_name = unique_cursor.conn.db_name
with self.temp_kudu_table(kudu_client, [INT32], db_name=db_name) as kudu_table:
@@ -221,10 +230,12 @@ class TestKuduHMSIntegration(CustomClusterTestSuite, KuduTestSuite):
@pytest.mark.execute_serially
@SkipIfHive3.kudu_hms_notifications_not_supported
+ @CustomClusterTestSuite.with_args(impalad_args="-kudu_client_rpc_timeout_ms=30000")
def test_drop_db_cascade(self, unique_cursor, kudu_client):
"""Check that an attempt to drop a database cascade will succeed even if Kudu
tables are present. Make sure the corresponding managed tables are removed
- from Kudu.
+ from Kudu. Increase timeout of individual Kudu client rpcs to avoid requests
+ fail due to operation delay in the Hive Metastore for managed tables (IMPALA-8856).
"""
db_name = unique_cursor.conn.db_name
with self.temp_kudu_table(kudu_client, [INT32], db_name=db_name) as kudu_table:
@@ -244,9 +255,12 @@ class TestKuduHMSIntegration(CustomClusterTestSuite, KuduTestSuite):
@pytest.mark.execute_serially
@SkipIfHive3.kudu_hms_notifications_not_supported
+ @CustomClusterTestSuite.with_args(impalad_args="-kudu_client_rpc_timeout_ms=30000")
def test_drop_managed_kudu_table(self, cursor, kudu_client, unique_database):
"""Check that dropping a managed Kudu table should fail if the underlying
- Kudu table has been dropped externally.
+ Kudu table has been dropped externally. Increase timeout of individual
+ Kudu client rpcs to avoid requests fail due to operation delay in the
+ Hive Metastore for managed tables (IMPALA-8856).
"""
impala_tbl_name = "foo"
cursor.execute("""CREATE TABLE %s.%s (a INT PRIMARY KEY) PARTITION BY HASH (a)