Repository navigation
Split the release-branch db disk integration job into 6 batches so it fits its session timeout - #112261
Split the release-branch db disk integration job into 6 batches so it fits its session timeout#112261groeneai wants to merge 3 commits into
Conversation
Integration tests (amd_asan_ubsan, db disk, N/4) is release-branch-only and
every shard is cut by its own session timeout:
xdist.dsession.Interrupted: session-timeout: 7200.0 sec exceeded
The split does not fit the budget. On AMD_MEDIUM the job gets
min(ncpu // MAX_CPUS_PER_WORKER, mem_gb // MAX_MEM_PER_WORKER)
= min(16 // 5, 61 // 11) = 3 workers, and session_timeout_parallel is
3600 * 2 = 7200 s, so a shard has 21600 worker-seconds. The integration
corpus measures ~90800 s on master and ~86500 s on 26.6, so a quarter of it
is ~22000 s, over 100% of the budget before any scheduling loss. Whichever
modules the workers are running when the clock expires get reported as
failures, which is why both the failing modules and the failing shard index
differ from branch to branch.
Measured over 12 days on master-less refs (CIDB, pull_request_number = 0),
counting SHAs whose run emitted the Timeout pseudo-test: 26.7 shard 1/4
28/28 and shard 3/4 28/28, 26.6 shard 4/4 47/47 and shard 2/4 42/47,
26.5 shard 3/4 27/33, 26.4 shard 3/4 21/35. Those per-shard duration sums
are censored, since the run is cut at the budget, so the true demand is at
least that.
The sibling db disk, old analyzer, N/6 job runs the same corpus on the same
runner with the same worker count and the same budget and has no timeouts at
all, at 13263-17445 test-seconds per shard (61-81% of budget over 256 master
SHAs). This gives db disk the same 6-way split: with real measured
per-module durations fed through the in-tree get_optimal_test_batch(), the
worst shard goes from 109.8% to 76.7% of budget on master and from 103.6% to
75.6% on 26.6, with no shard over budget in either case.
Two plausible causes are ruled out by measurement. It is not memory: both
sampled job.log files contain no out-of-memory line, the shard that timed out
with 1405 passed and 0 failed has no node-down line either, and the harness's
own OOM in dmesg check reports nothing for any db disk shard over 20 days.
It is not a stale RAW_TEST_DURATIONS table: 26.7 carries the refreshed table
and has the worst timeout rate of any branch, and the static table's 4-way
spread is only 1.1% imbalanced, which cannot explain a 100% overrun.
Batch count alone does not imply overload, so two other 4-way integration
jobs are left alone: arm_binary, distributed plan, N/4 and amd_cfi, N/4 both
have no timeouts because they run filtered subsets totalling about 43000 s
and 41500 s, under half the corpus. All seven parametrized integration jobs
were checked; db disk, N/4 is the only one over budget.
6 rather than 8 follows e1b6984, which reverted the old analyzer
sibling from 8 back to 6.
.github/workflows/release_branches.yml is regenerated with
python3 -m ci.praktika yaml rather than edited by hand, and committed so that
_check_yaml_up_to_date does not have to push a corrective commit. It is the
only generated workflow that names this job.
Check names change from db disk, N/4 to db disk, N/6, so dashboards, mute
lists or saved queries keyed on the old literal stop matching and CIDB
history does not carry over. The same rename already happened for the old
analyzer sibling. No in-tree consumer hardcodes the old names.
Internal second-model review (3 findings, all agreed and fixed before publication)This change was reviewed independently before publication: a cold code review by a reviewer
The second-model pass over the diff itself returned no findings. No blocker was deferred and |
Pre-PR validation gate (click to expand)
Session id: cron:clickhouse-impl-slot-45:20260728-095000 |
|
cc @leshikus - could you review this? It changes the release-branch-only |
CI finish ledger - 293124dCI fully finished on this head: 174 check-runs, 0 queued or in progress,
Session id: cron:our-pr-ci-monitor:20260728-130000 |
Resolve the generated praktika workflow YAML by regenerating it (`python3 -m ci.praktika yaml`) from the merged `ci/` sources, rather than textually merging the single generated `needs:` line.
Build profile diff (arm_release)Comparing ✅ No significant changes. Binary sizes
Only the stripped binary is compared: the official master build keeps debug symbols while PR builds strip them, so the other binaries differ by construction. Compile time of recompiled translation units6 translation units recompiled, 4 s compile time in total, 6 of them have a recent master baseline. |
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
...
Description
Integration tests (amd_asan_ubsan, db disk, N/4)runs only on release branches and everyshard is cut by its own session timeout:
The split does not fit the budget. The job runs on
AMD_MEDIUM, whereintegration_test_job.py:722sizes workers asmin(ncpu // MAX_CPUS_PER_WORKER, mem_gb // MAX_MEM_PER_WORKER) = min(16 // 5, 61 // 11) = 3(confirmed in
job.log:ncpu: 16,mem_gb: 61,-n 3 --dist=loadfile). The parallelphase gets
session_timeout_parallel = 3600 * 2 = 7200s, so one shard has7200 x 3 = 21 600 worker-seconds, while the integration corpus measures at least
~90 800 s on master and ~86 500 s on 26.6 (a lower bound: measured durations cover
1 013 of the 1 044 test modules in the tree) - a quarter of it is ~22 000 s, i.e. over
100 % of the budget before any scheduling loss. Whichever modules the workers happen to be running when
the clock expires get reported as failures, which is why both the failing modules and the
failing shard index differ from branch to branch.
Measured (CIDB, 12 d,
pull_request_number = 0);timeout runscounts SHAs whose runemitted the
Timeoutpseudo-test:Those per-shard figures are censored: the run is cut at the budget, so the sum clusters
just under 21 600 because the clock ran out, not because the work was 21 600 s. The true
demand is at least that.
The sibling
db disk, old analyzer, N/6job runs the same corpus on the same runner with thesame sanitizer build, the same worker count and the same budget, and has 0 timeouts
(13 263 - 17 445 test-seconds per shard, 61-81 % of budget; 256 master SHAs). That sibling
also gives an uncensored measurement of the corpus, since its runs are not truncated. On 26.6
sha
7367c762184ba3f6bce70b7905084f326654e305its six shards summed to13 800 / 15 130 / 15 379 / 16 745 / 14 180 / 13 429 = 88 663 test-seconds, worst shard
77.5 % of budget. Split that same measured total 4 ways instead and a shard needs 22 166 s,
102.6 % of the 21 600 worker-second budget; 6 ways gives 14 777 s, 68.4 %. This change
gives the
db diskjob the same 6-way split.With real measured per-module durations, the assignment produced by the in-tree
get_optimal_test_batch():6 rather than 8 follows
e1b6984c9341e96, which reverted theold analyzersibling from 8back to 6. The worst 6-way shard sits at about 77 % of budget, so a ~25 % corpus growth
re-opens this; 6 is the value that both fits today and matches that decision.
Runner cost is roughly unchanged: two more concurrent
AMD_MEDIUMjobs per release-branchpush, each about two thirds of the work of an old shard, against runs that currently burn a
full two hours only to be aborted.
A shard times out with zero test failures
The clearest evidence that the timeout is the cause and the test failures are the symptom
is shard 4/4 on 26.6 sha
3ffa9682053c719b7e7edd8e94f49d858e4aa7eb:Last progress marker
[gw2] [ 94%]. Shard 1/4 on sha7367c762184ba3f6bce70b7905084f326654e305reached[gw3] [ 96%]and reported7 failed, 1062 passed, 79 skipped, 9 errors in 7302.32s. So today roughly 4-6 % of eachover-budget shard never executes, and the truncation is reported as test failures.
Two plausible causes that the measurements rule out
Memory pressure:
grep -c "Out of memory"andgrep -c "OOM"are both 0 on those twojob.logfiles, the 4/4 log has nonode downline at all and still timed out, and theharness's own
OOM in dmesgcheck reports zero rows for everydb diskshard over 20 days.Stale
RAW_TEST_DURATIONS: 26.7 carries the refreshed table and has the worst timeout rateof any branch (28/28 on 1/4, 28/28 on 3/4). A better duration table only rebalances within a
total that does not fit; the static table's 4-way spread is 9 188 / 9 184 / 9 283 / 9 188 s,
an imbalance of 1.1 %.
Batch count alone does not imply overload
Two other 4-way integration jobs are healthy and are deliberately left alone:
arm_binary, distributed plan, N/4(0 timeouts over 258 SHAs, 9 680-11 177 test-seconds pershard) and
amd_cfi, N/4(0 timeouts, 8 940-11 099). They run the same module set -get_parallel_sequential_tests_to_runglobs the whole corpus and its only corpus filter isgated on
amd_llvm_coverage, which neither takes - and their per-shard module counts are inthe same range as this job's (arm_binary 239-284 per shard against
db disk's 189-229). Whatdiffers is the build: they run
CH_ARM_BINARYandCH_AMD_CFI, this job runsCH_AMD_ASAN_UBSAN. Comparing the same module measured under both, the median per-moduleratio is 2.03 for asan against arm_binary (87 734 s against 44 484 s over 1 032 common
modules) and 2.12 against cfi (89 267 s against 42 759 s over 1 038). So a sanitizer build
roughly doubles the wall-clock of an identical corpus, which is why 4 batches fit one and not
the other. All seven parametrized integration jobs were checked against CIDB;
db disk, N/4is the only one over budget.
Notes
.github/workflows/release_branches.ymlis regenerated withpython3 -m ci.praktika yamlrather than edited by hand, and is committed here so that
_check_yaml_up_to_datedoes nothave to push a corrective commit. It is the only generated workflow that names this job.
Check names change from
db disk, N/4todb disk, N/6, so dashboards, mute lists or savedqueries keyed on the old literal stop matching and CIDB history does not carry over. The same
rename already happened for the
old analyzersibling ine1b6984c9341e96. No in-treeconsumer hardcodes the old names.
This PR's own CI cannot exercise ReleaseBranchCI, so it does not test the change. After it
reaches a release branch the
db disk, N/6shards should show noTimeoutrows.Release branches do not receive master CI-config commits after they are cut - each runs
ReleaseBranchCI from its own committed
release_branches.yml, andgit rev-list --count $(git merge-base origin/master origin/26.6)..origin/26.6 -- ci/defs/job_configs.pyis 0 - so merging this fixes 26.8 and later, but not the live branches. Could a maintainer
apply the appropriate
vX.Y-must-backportlabel once this is merged? A version-specificlabel expands to that release plus every newer active branch, so
v26.4-must-backportwouldcover 26.4 through 26.7 in one go. I am not hand-authoring release-branch PRs.
Workflow [PR]
Sync PR [sync-upstream/pr/112261]