You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@impala.apache.org by st...@apache.org on 2021/01/13 01:08:52 UTC

[impala] 05/18: IMPALA-9650: Fix flakiness in RuntimeFilterTest

This is an automated email from the ASF dual-hosted git repository.

stigahuang pushed a commit to branch 3.x
in repository https://gitbox.apache.org/repos/asf/impala.git

commit c1af049b6bd5ab147394da10a18cf6700bff7dae
Author: Riza Suminto <ri...@cloudera.com>
AuthorDate: Mon Apr 13 15:19:59 2020 -0700

    IMPALA-9650: Fix flakiness in RuntimeFilterTest
    
    IMPALA-9612 adds RuntimeFilterTest to the set of backend tests. It
    adds a delay injection code in runtime-filter.cc to reproduce the race
    condition. However, the delay injection code will be stripped out when
    Impala is build with release config. This patch remove the NDEBUG
    macro enclosing the delay injection code so that it will not be
    stripped out in release build.
    
    Testing:
    - Ran and pass pass backend tests against release build.
    
    Change-Id: Ie3a5e68a128a97524755eeee4f8a993f38a0ed48
    Reviewed-on: http://gerrit.cloudera.org:8080/15726
    Reviewed-by: Impala Public Jenkins <im...@cloudera.com>
    Tested-by: Impala Public Jenkins <im...@cloudera.com>
    (cherry picked from commit 8d264321efe370924b3e60fafad9aca1347a4dc1)
---
 be/src/runtime/runtime-filter.cc | 2 --
 1 file changed, 2 deletions(-)

diff --git a/be/src/runtime/runtime-filter.cc b/be/src/runtime/runtime-filter.cc
index 1ff0a13..04be0ab 100644
--- a/be/src/runtime/runtime-filter.cc
+++ b/be/src/runtime/runtime-filter.cc
@@ -81,9 +81,7 @@ bool RuntimeFilter::WaitForArrival(int32_t timeout_ms) const {
     int64_t ms_since_registration = MonotonicMillis() - registration_time_;
     int64_t ms_remaining = timeout_ms - ms_since_registration;
     if (ms_remaining <= 0) break;
-#ifndef NDEBUG
     if (injection_delay_ > 0) SleepForMs(injection_delay_);
-#endif
     arrival_cv_.WaitFor(l, ms_remaining * MICROS_PER_MILLI);
   }
   return arrival_time_.Load() != 0;