Repository navigation
Description
Describe the situation
On antalya-26.8, a swarm query waits the full receive_timeout (300 s) when the swarm nodes are frozen (process stopped, socket still open). It used to fail fast with ALL_CONNECTION_TRIES_FAILED.
- Expected (antalya-26.6 and earlier): the query fails in seconds with
Code: 279. Cannot connect to any replica for query execution. - Actual (antalya-26.8): the query hangs for 300 s, then fails with
Code: 209. SOCKET_TIMEOUT ... receive timeout 300000 ms: While executing Remote.
The same thing affects a single frozen node: /swarms/feature/node failure/cpu overload sometimes waits 300 s instead of finishing on the remaining node.
How to reproduce
python3 -u swarms/regression.py \
--clickhouse https://altinity-build-artifacts.s3.amazonaws.com/REFs/antalya-26.8/cafe527645a45eae83bdbacdfffbd01124ef20fa/build_amd_binary/clickhouse \
--clickhouse-version 26.8.34.20001.altinityantalya \
--with-analyzer \
--log log.log \
--only \
'/swarms/feature/node failure/cpu overload all swarm nodes/*'The test stops both swarm nodes with kill -STOP and runs a query from the initiator.
Cause
Upstream ClickHouse#110068 ("Do not ping pooled connections before use") removed the ping on pooled connections. Now a pooled connection is checked only with a zero-timeout poll, which detects a closed socket but not a hung server. The upstream code says so: "A server that went away without closing the connection is not detected here".
- Before: the ping to a frozen node timed out in seconds, and the node was skipped.
- Now: the initiator sends the query over the pooled connection and waits for
receive_timeout.
Distributed tables are still covered by the TablesStatus request (sync_request_timeout) and by hedged requests. Cluster table functions (s3Cluster, icebergCluster, object_storage_cluster) go through ReadFromCluster::initializePipeline, which has neither. That makes swarms the most exposed path.
Possible fix
Validate pooled connections again (a ping with sync_request_timeout), but only on the cluster/swarm path (skip_unavailable_endpoints), so the upstream latency gain is kept everywhere else.
Additional context
- CI failure: antalya-26.8 run 43534391248, job Swarms x86
- The test fails 100% of the time on antalya-26.8 (since 2026-10-06) and passes on 25.8, 26.1, 26.3 and 26.6.
Activity
[-]26.8+: Swarm query hangs for receive_timeout (300 s) when swarm nodes are frozen[/-][+]Antalya 26.8+: Swarm query hangs for receive_timeout (300 s) when swarm nodes are frozen[/+][-]Antalya 26.8+: Swarm query hangs for receive_timeout (300 s) when swarm nodes are frozen[/-][+]Antalya 26.8: Swarm query hangs for receive_timeout (300 s) when swarm nodes are frozen[/+]ianton-ru commentedon Nov 18, 2026
Swarm is not a special feature, it's a cluster role, so initiator does not have a mark is the cluster swarm or just a regular cluster.
May be something like:
ping nodes of the cluster when initiator is not a cluster member. In this case all nodes in cluster can be unaccessible, and query has no chance to be executed. When initiator is a member, query can be executed on the initiator as a last node alive.