You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
Repository navigation
Commit b2f346c
Browse filesBrowse the repository at this point in the historyBrowse files
[fix](fe) Take the last-chance cancellation check on the auto-detect route too
An auto-detect overwrite (PARTITION(*)) publishes through the overwrite manager, so it
bypassed the check the explicit-partition route got. With enable_strict_consistency_dml
off, an empty-plan auto-detect overwrite has no exchange in its plan -- VEMPTYSET is the
sink's direct child -- so it takes the insert's no-transaction path, and a cancellation
landing while the swap waits for the table lock was answered with a success for a
statement that did nothing. Both routes now publish through one place that holds the
target table's write lock and reads the flag under it.
Key changes:
- publishTheOverwrite takes the publication as an action, so the explicit-partition swap
and the auto-detect task group share the same last-chance decision, and the same
failure for a target that was dropped.
- The suite drives the auto-detect shape: with strict DML consistency off, a cancelled
PARTITION(*) overwrite of an empty plan fails and the table keeps its rows.
Unit Test:
- regression-test/suites/insert_overwrite_p0/test_insert_overwrite_cancel.groovy
- test_insert_overwrite_cancel, test_iot_auto_detect, test_iot_auto_detect_fail,
test_iot_auto_detect_concurrent, test_iot_overwrite_and_create and
mtmv_p0/ivm/test_ivm_basic_mtmv pass.
Copy file name to clipboardExpand all lines: fe/fe-core/src/main/java/org/apache/doris/nereids/trees/plans/commands/insert/InsertOverwriteTableCommand.java
+35-16Lines changed: 35 additions & 16 deletions
Original file line number
Diff line number
Diff line change
@@ -146,6 +146,17 @@ public class InsertOverwriteTableCommand extends Command
0 commit comments