924060929 opened a new pull request, #68283:
URL: https://github.com/apache/doris/pull/68283

   ### What problem does this PR solve?\n\nA statement publishes its query ID 
before planning completes so it remains observable and can be cancelled. INSERT 
and row-level DML statements, however, may not publish their coordinator until 
transaction preparation and sink finalization finish.\n\nIf KILL QUERY arrives 
in that window, StmtExecutor receives the cancellation while its coordinator is 
still null. The cancellation was therefore lost, and the coordinator created 
later could continue to dispatch fragments.\n\nThis PR:\n\n- preserves the 
first cancellation reason in StmtExecutor and hands it to a coordinator when 
the coordinator is published;\n- prevents the legacy coordinator from 
dispatching fragments after cancellation under its existing coordinator 
lock;\n- prevents the Nereids pipeline coordinator from dispatching fragments 
after cancellation under its existing coordinator-context lock;\n- keeps the 
query ID visible during planning, so KILL QUERY can still find the running s
 tatement.\n\n### Release note\n\nFix KILL QUERY cancellation during INSERT and 
DML planning.\n\n### Check List (For Author)\n\n- Test:\n  - Added FE unit 
tests covering cancellation before coordinator publication, after coordinator 
publication, and before fragment dispatch in both coordinator 
implementations.\n  - Ran the four targeted FE unit tests: 4 passed, 0 
failed.\n  - Ran FE Checkstyle: 0 violations.\n- Behavior changed: Yes. 
Statements cancelled during planning no longer dispatch fragments after their 
coordinator is created.\n- Does this need documentation: No


-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]


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

Reply via email to