Skip to content

Remove no-parallel tag for some tests - #126555

Merged
alexey-milovidov merged 4 commits into
ClickHouse:masterfrom
murphy-4o:tests-drop-unneeded-no-parallel
Oct 21, 2026
Merged

alexey-milovidov merged 4 commits into
ClickHouse:masterfrom
murphy-4o:tests-drop-unneeded-no-parallel

Conversation

@murphy-4o

@murphy-4o murphy-4o commented Oct 18, 2026 •

Copy link
Copy Markdown
Member

Fast test spends half of its Tests step running no-parallel tests one at a time:

Tests step ≈ 494 s (m8g.8xlarge, --jobs 24)
  parallel phase     ≈ 256 s   24 workers, shared queue
  sequential phase   ≈ 234 s   1 worker, 540 `no-parallel` tests   ← 23 workers idle

For 27 of them the tag's reason does not hold:

global name (user, database, settings profile)              ← unique per run, or per test where the flaky check skips it,
                                                               or made unique here (05026)
"checks thread count / metrics"                             ← per query_id, upper bounds only
"writes ZooKeeper by hand / creates database"               ← the test's own paths and databases

Drop no-parallel from them (and the stale reason comments). They take ~35 s of the sequential phase; in the parallel pool that is ~2 s, so the Tests step should shrink by ~33 s.

Changelog category (leave one):

  • CI Fix or Improvement (changelog entry is not required)

🤖 Generated with Claude Code


Workflow [PR]
Sync PR [sync-upstream/pr/126555]

Version info

  • Merged into: 26.11.1.377-master (included in 26.11 and later)

Their tag reasons no longer hold: global names are already unique to
the test or are made unique here, and the remaining reasons do not match
what the tests do (per-query metrics, the test's own ZooKeeper paths,
own databases). Together they are ~51 s of Fast test's sequential phase.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@clickhouse-gh

clickhouse-gh Bot commented Oct 18, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [b0ac572]

Summary: ✅


AI Review

Summary

Removes no-parallel from 27 stateless tests and gives test 05026 per-run user and database names. Both previous findings are addressed by retaining no-parallel on tests with shared resources. No unresolved findings remain at commit b0ac572f746f340b9060f0d0cdcc41579a7f92af; all 27 changed tests passed in the Fast test report.

Final Verdict

Status: ✅ Approve

@clickhouse-gh clickhouse-gh Bot added pr-ci comp-testing Test content only (no production code). labels Oct 18, 2026
The style check requires the tag for any test with SYSTEM DROP.
02888, 03169, 03919 and 05333 drop replicas of their own tables only,
but stay sequential rather than widening that check here.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@murphy-4o murphy-4o changed the title Run 42 tests tagged no-parallel in the parallel pool Run 38 tests tagged no-parallel in the parallel pool Oct 18, 2026
The flaky check runs copies of a changed test at the same time. These
nine use server-wide names that are unique across tests but shared by
copies of the same test (roles, row policies, named collections, a
fixed table UUID, a fixed user_files path), and 01307 runs too long
when its copies overlap.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@murphy-4o murphy-4o changed the title Run 38 tests tagged no-parallel in the parallel pool Run 29 tests tagged no-parallel in the parallel pool Oct 18, 2026
Their UDF and named collection have fixed names, so concurrent copies in
the flaky check drop each other's object.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@murphy-4o murphy-4o changed the title Run 29 tests tagged no-parallel in the parallel pool Run 27 tests tagged no-parallel in the parallel pool Oct 18, 2026
@murphy-4o
murphy-4o marked this pull request as ready for review October 19, 2026 07:57
@murphy-4o murphy-4o changed the title Run 27 tests tagged no-parallel in the parallel pool Run some tests tagged no-parallel in the parallel pool Oct 19, 2026
@murphy-4o murphy-4o changed the title Run some tests tagged no-parallel in the parallel pool Remove no-parallel tag for some tests Oct 19, 2026
@alexey-milovidov alexey-milovidov self-assigned this Oct 21, 2026
@alexey-milovidov
alexey-milovidov added this pull request to the merge queue Oct 21, 2026
Merged via the queue into ClickHouse:master with commit 60a3703 Oct 21, 2026
178 checks passed
@robot-ch-test-poll3 robot-ch-test-poll3 added the pr-synced-to-cloud The PR is synced to the cloud repo label Oct 21, 2026
groeneai added a commit to groeneai/ClickHouse that referenced this pull request Oct 26, 2026
…list

When the client cancels a query over the native protocol (a `Cancel` packet, or the
connection dropping while the handler polls it), `TCPHandler` cancelled the pipeline
executor and then waited for its threads, but never marked the query as cancelled in the
process list. Code that observes cancellation only through the process list entry kept
running: `sleep` loops on `QueryStatus::checkTimeLimit`, so a cancelled query slept
through its whole block while the handler waited in `PullingAsyncPipelineExecutor::cancel`.
`KILL QUERY` and the `clickhouse-local` cancel callback already mark the entry.

Under parallel replicas this made `04117_detach_database_kill_query` flaky once ClickHouse#126555
moved it to the parallel pool: the follower that got the table's only mark kept sleeping
~300 s after the initiator was killed and tripped the final hung check (`is_cancelled` 0 in
every dump). Since the follower now stops, the `no-parallel-replicas` tag is dropped again.

Now the handler cancels the process list entry before cancelling the executor, for both the
pulling and the completed pipeline paths, passing the client's exception so that the query
still fails with `QUERY_WAS_CANCELLED_BY_CLIENT`.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
wilkermichael pushed a commit to Shopify/ClickHouse that referenced this pull request Nov 3, 2026
Since ClickHouse#126555 moved the test into the parallel pool, the ParallelReplicas
lane reports `Some queries hung` on master (2 of 21 runs). The table has
one mark; when a remote replica reads it, the whole 300 s `sleepEachRow`
block runs in a secondary query with its own query_id. The test's
`KILL QUERY WHERE query_id = ...` kills only the initial query, and
`sleep` stops only when its own query is killed, so the secondary
outlives the test and the end-of-run hung check catches it.

Parallel replicas add nothing to what the test checks (KILL QUERY
interrupting the DETACH DATABASE wait), so tag it `no-parallel-replicas`:
the lane skips it and other lanes run it with enable_parallel_replicas = 0.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

comp-testing Test content only (no production code). pr-ci pr-synced-to-cloud The PR is synced to the cloud repo

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants