Return-Path: X-Original-To: archive-asf-public-internal@cust-asf2.ponee.io Delivered-To: archive-asf-public-internal@cust-asf2.ponee.io Received: from cust-asf.ponee.io (cust-asf.ponee.io [163.172.22.183]) by cust-asf2.ponee.io (Postfix) with ESMTP id C8A8C200CAF for ; Thu, 22 Jun 2017 23:19:58 +0200 (CEST) Received: by cust-asf.ponee.io (Postfix) id C5B9B160BD3; Thu, 22 Jun 2017 21:19:58 +0000 (UTC) Delivered-To: archive-asf-public@cust-asf.ponee.io Received: from mail.apache.org (hermes.apache.org [140.211.11.3]) by cust-asf.ponee.io (Postfix) with SMTP id 1675B160BF4 for ; Thu, 22 Jun 2017 23:19:57 +0200 (CEST) Received: (qmail 89899 invoked by uid 500); 22 Jun 2017 21:19:57 -0000 Mailing-List: contact commits-help@kudu.apache.org; run by ezmlm Precedence: bulk List-Help: List-Unsubscribe: List-Post: List-Id: Reply-To: dev@kudu.apache.org Delivered-To: mailing list commits@kudu.apache.org Received: (qmail 89853 invoked by uid 99); 22 Jun 2017 21:19:57 -0000 Received: from git1-us-west.apache.org (HELO git1-us-west.apache.org) (140.211.11.23) by apache.org (qpsmtpd/0.29) with ESMTP; Thu, 22 Jun 2017 21:19:57 +0000 Received: by git1-us-west.apache.org (ASF Mail Server at git1-us-west.apache.org, from userid 33) id 68EC3E03B3; Thu, 22 Jun 2017 21:19:56 +0000 (UTC) Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit From: alexey@apache.org To: commits@kudu.apache.org Date: Thu, 22 Jun 2017 21:19:59 -0000 Message-Id: <2d66655993f54632a0a30a7deee82835@git.apache.org> In-Reply-To: <359de2a34f6a47c89ec4fa2f24fb5c28@git.apache.org> References: <359de2a34f6a47c89ec4fa2f24fb5c28@git.apache.org> X-Mailer: ASF-Git Admin Mailer Subject: [4/4] kudu git commit: [client-test] fixing flakes in the test archived-at: Thu, 22 Jun 2017 21:19:59 -0000 [client-test] fixing flakes in the test Extended timeout for table creation up to 60 seconds in couple of places where dist-test reports intermittent timeouts. Added print-out of the session errors if the actual number of session errors differs from the expected one (that's for TestAutoFlushBackgroundAndErrorCollector) Change-Id: Ic0203e62ec8ee445201e385816f3c05c2594356d Reviewed-on: http://gerrit.cloudera.org:8080/7263 Tested-by: Kudu Jenkins Reviewed-by: Adar Dembo Project: http://git-wip-us.apache.org/repos/asf/kudu/repo Commit: http://git-wip-us.apache.org/repos/asf/kudu/commit/d2b82059 Tree: http://git-wip-us.apache.org/repos/asf/kudu/tree/d2b82059 Diff: http://git-wip-us.apache.org/repos/asf/kudu/diff/d2b82059 Branch: refs/heads/master Commit: d2b8205941d22ba8ffc5d105b3612ecdc58e9fd7 Parents: c257785 Author: Alexey Serbin Authored: Thu Jun 22 08:19:52 2017 -0700 Committer: Alexey Serbin Committed: Thu Jun 22 21:08:14 2017 +0000 ---------------------------------------------------------------------- src/kudu/client/client-test.cc | 14 +++++++++++--- 1 file changed, 11 insertions(+), 3 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/kudu/blob/d2b82059/src/kudu/client/client-test.cc ---------------------------------------------------------------------- diff --git a/src/kudu/client/client-test.cc b/src/kudu/client/client-test.cc index a7c5070..a019f0d 100644 --- a/src/kudu/client/client-test.cc +++ b/src/kudu/client/client-test.cc @@ -562,6 +562,7 @@ class ClientTest : public KuduTest { .schema(&schema_) .num_replicas(num_replicas) .set_range_partition_columns({ "key" }) + .timeout(MonoDelta::FromSeconds(60)) .Create()); ASSERT_OK(client_->OpenTable(table_name, table)); @@ -2726,7 +2727,6 @@ TEST_F(ClientTest, TestAutoFlushBackgroundAndErrorCollector) { } void AddError(unique_ptr error) override { - //LOG(INFO) << "Hello from: " << Thread::UniqueThreadId(); if (0 == error_cnt_++) { const bool prev_allowed = ThreadRestrictions::SetWaitAllowed(true); SleepFor(MonoDelta::FromSeconds(1)); @@ -2768,7 +2768,15 @@ TEST_F(ClientTest, TestAutoFlushBackgroundAndErrorCollector) { bool overflowed; session->GetPendingErrors(&errors, &overflowed); ASSERT_FALSE(overflowed); - ASSERT_EQ(kRowNum, errors.size()); + // Print out the errors if the expected count differs from the actual one. + if (kRowNum != errors.size()) { + vector errors_str; + for (const auto e : errors) { + errors_str.push_back(Substitute("status: $0; operation: $1", + e->status().ToString(), e->failed_op().ToString())); + } + EXPECT_EQ(kRowNum, errors.size()) << errors_str; + } } } @@ -5120,7 +5128,7 @@ static const ServiceUnavailableRetryParams service_unavailable_retry_cases[] = { // request for long enough time. { MonoDelta::FromSeconds(1), // usurper_sleep - MonoDelta::FromSeconds(10), // client_timeout + MonoDelta::FromSeconds(60), // client_timeout &Status::ok, // status_check }, };