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

boroknagyz pushed a commit to branch master
in repository https://gitbox.apache.org/repos/asf/impala.git

commit fc152b376cc8cede7a91c370a53274738ec9c8b0
Author: Riza Suminto <[email protected]>
AuthorDate: Sun Mar 2 11:54:44 2025 -0800

    IMPALA-13816: Reduce test_queue_reasons_slots
    
    test_queue_reasons_slots continues to be flaky in ASAN build even after
    fix from IMPALA-10338.
    
    This patch reduce / simplify the test by making the test query run
    faster and raise timeout value sufficiently high in slow build flavor by:
    1. Lowering MT_DOP to 2.
    2. Limit scanning just 6 partitions of store_sales.
    3. Reduce number of parallel query from 5 to 3.
    4. Replace TIMEOUT_S with STRESS_TIMEOUT, which is equal to 90s in
       normal build and 600s in slow build.
    
    Testing:
    - Loop the test 50x in ASAN build.
    
    Change-Id: Ic2d6d68d381d22c599d4c5cdc78cc997ddef749b
    Reviewed-on: http://gerrit.cloudera.org:8080/22566
    Reviewed-by: Impala Public Jenkins <[email protected]>
    Tested-by: Impala Public Jenkins <[email protected]>
---
 tests/custom_cluster/test_admission_controller.py | 20 +++++++++++++-------
 1 file changed, 13 insertions(+), 7 deletions(-)

diff --git a/tests/custom_cluster/test_admission_controller.py 
b/tests/custom_cluster/test_admission_controller.py
index bdaeb72a8..6a94ceaf9 100644
--- a/tests/custom_cluster/test_admission_controller.py
+++ b/tests/custom_cluster/test_admission_controller.py
@@ -1056,27 +1056,33 @@ class 
TestAdmissionController(TestAdmissionControllerBase, HS2TestSuite):
   @pytest.mark.execute_serially
   @CustomClusterTestSuite.with_args(
       impalad_args=impalad_admission_ctrl_flags(max_requests=100, 
max_queued=10,
-          pool_max_mem=-1, admission_control_slots=8,
+          pool_max_mem=-1, admission_control_slots=2,
           executor_groups="default-pool-group1"),
       statestored_args=_STATESTORED_ARGS)
   def test_queue_reasons_slots(self):
     """Test that queue details appear in the profile when queued based on 
number of
     slots."""
     # Run a bunch of queries - one should get admitted immediately, the rest 
should
-    # be dequeued one-by-one. This is achieved by running 5 Aggregation 
queries in
+    # be dequeued one-by-one. This is achieved by running 3 Aggregation 
queries in
     # parallel with MT_DOP option equals to available number of slots in each 
Impalad
-    # executor.
-    STMT = "select min(ss_wholesale_cost) from tpcds_parquet.store_sales"
-    TIMEOUT_S = 60
+    # executor. Each ScanNode instance read one partition of store_sales.
+    cluster_size = len(self.cluster.impalads)
+    mt_dop = 2
+    num_part = cluster_size * mt_dop
+    part_begin = 2450816
+    part_end = part_begin + num_part - 1
+    # This query runs for roughly 2s in normal build.
+    STMT = ("select min(ss_wholesale_cost) from tpcds_parquet.store_sales "
+            "where ss_sold_date_sk between {} and {}").format(part_begin, 
part_end)
     EXPECTED_REASON = "Latest admission queue reason: Not enough admission 
control " +\
                       "slots available on host"
-    NUM_QUERIES = 5
+    NUM_QUERIES = 3
     coordinator_limited_metric = \
       "admission-controller.total-dequeue-failed-coordinator-limited"
     original_metric_value = self.get_ac_process().service.get_metric_value(
         coordinator_limited_metric)
     profiles = self._execute_and_collect_profiles([STMT for i in 
range(NUM_QUERIES)],
-        TIMEOUT_S, config_options={"mt_dop": 8})
+        STRESS_TIMEOUT, config_options={"mt_dop": mt_dop})
 
     num_reasons = len([profile for profile in profiles if EXPECTED_REASON in 
profile])
     assert num_reasons == NUM_QUERIES - 1, \

Reply via email to