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

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


The following commit(s) were added to refs/heads/master by this push:
     new 18967f28a39 [fix](test) Deflake insert overwrite auto detect failure 
(#67571)
18967f28a39 is described below

commit 18967f28a3976e73c236b4db02fa53ffa9ed8e92
Author: hui lai <[email protected]>
AuthorDate: Wed Sep 9 12:58:20 2026 +0800

    [fix](test) Deflake insert overwrite auto detect failure (#67571)
    
    ### What problem does this PR solve?
    
    Issue Number: None
    
    Related PR: #64580
    
    Problem Summary: INSERT OVERWRITE auto-detect must fail when source rows
    do not match an existing target partition and automatic partition
    creation is disabled. With multiple parallel sink instances, several
    equivalent failure messages can race to reach the client. The regression
    test accepted only one message, making repeated executions flaky. Accept
    the known equivalent errors while still requiring every statement to
    fail.
    
    ### Release note
    
    None
    
    ### Check List (For Author)
    
    - Test: Regression test updated; not run locally as requested, CI will
    execute it
    - Behavior changed: No
    - Does this need documentation: No
---
 .../test_iot_auto_detect_fail.groovy                   | 18 +++++++++++++++---
 1 file changed, 15 insertions(+), 3 deletions(-)

diff --git 
a/regression-test/suites/insert_overwrite_p0/test_iot_auto_detect_fail.groovy 
b/regression-test/suites/insert_overwrite_p0/test_iot_auto_detect_fail.groovy
index e6497b92447..2732836b7b3 100644
--- 
a/regression-test/suites/insert_overwrite_p0/test_iot_auto_detect_fail.groovy
+++ 
b/regression-test/suites/insert_overwrite_p0/test_iot_auto_detect_fail.groovy
@@ -150,16 +150,28 @@ PROPERTIES (
 );
     """
 
+    // The overwrite must fail because the source rows fall into a partition 
that does not exist
+    // in fail_tag and enable_auto_create_when_overwrite is false. With 
multiple parallel sink
+    // instances, equivalent errors can race to be reported. Accept each 
expected failure while
+    // still requiring the statement to fail.
+    def checkOverwriteFail = { result, exception, startTime, endTime ->
+        assertTrue(exception != null && (
+                exception.getMessage().contains('Cannot found origin 
partitions')
+                || exception.getMessage().contains('no partition for this 
tuple')
+                || exception.getMessage().contains('Insert has filtered data 
in strict mode')),
+            "expect insert-overwrite auto-detect to fail, "
+                + "but got result=${result}, 
exception=${exception?.getMessage()}")
+    }
     test {
         sql "insert overwrite table fail_tag PARTITION(*) select 
qsrq,lsh,wth,khh,dt from fail_src where dt='20241128';"
-        exception "Cannot found origin partitions"
+        check checkOverwriteFail
     }
     test {
         sql "insert overwrite table fail_tag PARTITION(*) select 
qsrq,lsh,wth,khh,dt from fail_src where dt='20241128';"
-        exception "Cannot found origin partitions"
+        check checkOverwriteFail
     }
     test {
         sql "insert overwrite table fail_tag PARTITION(*) select 
qsrq,lsh,wth,khh,dt from fail_src where dt='20241128';"
-        exception "Cannot found origin partitions"
+        check checkOverwriteFail
     }
 }


---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to