Repository navigation
Revert "Revert "Mark a query as cancelled in the process list when its TCP client cancels it"" - #129311
Conversation
…s TCP client cancels it""
|
Workflow [PR], commit [5efa513] Summary: ✅
AI ReviewSummaryRestores process-list cancellation when a TCP client cancels or disconnects, so running pipeline work such as Final VerdictStatus: ✅ Approve |
|
Maybe also bring #129275 here? |
|
@groeneai I realize this in an internal PR. Please create a branch in your fork and commit there, then let me know when it's ready and I'll review it and pick the commits here |
|
Acknowledged. I'm checking which tests started failing after the merge; I'll put the fixes (starting with #129275's commit) on a branch in my fork on top of this PR's head, and post the branch with the list of failures here when it's ready. |
|
The branch is ready: https://github.com/groeneai/ClickHouse/commits/reland-127149-ci-fixes It is master, then a re-land commit with the same tree as this PR's 7244105, then the commit to pick: 213a5d0 (#129275's fix, unchanged; it applies cleanly on 7244105). If you pick it here, I'll close #129275. What #127149 broke between its merge (2026-11-03 22:39 UTC) and the revert (2026-11-04 15:40 UTC), from CIDB:
Nothing else: no other failure after the merge mentions |
Build profile diff (arm_release)Comparing ✅ No significant changes. Binary sizes
The official master build is compiled with Compile time of recompiled translation units7 translation units recompiled, 9 s compile time in total, 7 of them have a recent master baseline. |
|
I added the So the commits to pick are 213a5d0 and a2e73c1 (not the re-land commit before them, which has the same tree as this PR's head). |
…ynchronousBoundedReadBuffer When a query reading object storage with prefetch is killed (or its TCP client cancels it), an in-flight prefetch can fail with the query's own stored cancellation: a failed S3 GET attempt makes `ReadBufferFromS3::processException` rethrow it via `CurrentThread::checkIfNotCancelled`. The future of that prefetch is never consumed, so `~AsynchronousBoundedReadBuffer` drains it in `finalize` and logged it at error level; with `send_logs_level` the line also reached the client, which failed `03312_squashing_with_low_card_mem_usage` with `having stderror` in the ParallelReplicas s3 jobs, where the initiator cancels its replicas once `LIMIT` is satisfied. Log it at debug level when the current thread's query is cancelled, as `AsyncInsertQueueTransform` already does for the same case. Co-Authored-By: Claude Opus 5.5 <[email protected]>
The test took ~18 s in Fast test because its 8 independent cases ran one after another and each one is ~2.2 s of waiting: for its query to sleep for over a second, then for it to stop at the end of the current 1 s sleep slice. They now run four at a time (each case keeps a client running, and a sanitizer client takes hundreds of MiB of the test's memory limit), each writing to its own file, printed in the old order, and system.processes is polled over HTTP. Queries, wait conditions, cancel actions and the reference are unchanged. Fast test configuration, p50 of 10 runs: 18.4 s -> 4.9 s. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Reverts #129310
Workflow [PR]
Sync PR [sync-upstream/pr/129311]
Version info
26.11.1.1432-master(included in26.11and later)