Repository navigation
Fix flaky test 03100_lwu_30_join_cache - #125032
PedroTadim merged 3 commits into
Conversation
The test timed out in `Stateless tests (arm_binary, ParallelReplicas, s3 storage, sequential)` on PR ClickHouse#124829: the client waited 300 s for `OPTIMIZE ... FINAL`. The MergeTree randomizer drew `index_granularity = 20` with `min_bytes_for_wide_part = 1 GiB`, so the patch parts written by the UPDATE were Compact parts with 150,000 granules on S3. Applying them in the merge reads a compact patch part with two S3 GETs per granule: 300,038 GETs and a 558 s merge on CI, against 54 GETs and 1 s without randomization. Release builds get no granularity floor from the runner (it covers only slow builds and `long` tests), and this test is tagged off every slow build. Clamp both granularity settings with a per-test limits line. The row floor is 1000 rather than the usual 100 because at 100 the same draw still makes 60,000 GETs, about 110 s on CI. Granularity stays randomized above the bounds; the test checks patch application, which does not depend on it. Validated on the amd_binary build of ClickHouse#124829 against local MinIO: the CI draw replayed fails with return code 159 and 300,038 GETs; at the floor it makes 6,038 GETs and passes in 7-8 s (patch_parts_version v1 and v2); a runner patched to draw granularity 20..60 gets exactly 1000 / 100000 in every CREATE, and the raw draws come through when the line is corrupted; 50/50 randomized runs on S3 and on local disk. Co-Authored-By: Claude Opus 5.5 <[email protected]>
Internal second-model review: adjudication log (click to expand)Pre-publication review by an independent model (engine: codex; 0 findings;
Severity: ❌ blocker / Session id: cron:clickhouse-review-slot-9:20261010-035000 |
Pre-PR validation gate (click to expand)
Session id: cron:clickhouse-impl-slot-4:20261010-024000 |
|
Workflow [PR], commit [ecf8883] Summary: ✅ AI ReviewSummaryThe PR sets lower bounds of 8192 rows and 10485760 bytes for randomized granularity in Missing context / blind spots
Final Verdict✅ Approve. No review changes requested; normal CI completion remains pending. |
CI finish ledger - 72c0c58Every failure below has an owner: a fixing PR (mine or external), or a full-effort fix task
Session id: cron:our-pr-ci-monitor:20261010-090002 |
|
Fixing PR for 05227_lightweight_update_pending_rename (Fast test arm_darwin timeout) created: #125070 |
|
@groeneai is this PR still needed? |
|
Yes, it is still needed. The test is unchanged on master and keeps timing out on the
Master runs these lanes about 8x less often and has no failure yet, but its slowest run there already took 270 s. With the clamp from this PR ( |
The amd_binary flaky check runs the test under ThreadFuzzer, where the merge takes about 5x its CPU time. A draw at the old floor (index_granularity 1000) spent 169 s in OPTIMIZE FINAL and 184.9 s in total, over the 180 s per-run limit. The merge time follows the granule count, and at the old index_granularity_bytes floor of 100000 the patch parts (44 bytes per row) are cut into ~2300-row granules, so both floors move to the defaults. Failing job: https://s3.amazonaws.com/clickhouse-test-reports/json.html?PR=125032&sha=e84b91cb3e22a91e879603c3fb43274ca170d117&name_0=PR&name_1=Stateless%20tests%20%28amd_binary%2C%20flaky%20check%29 Co-Authored-By: Claude Opus 5.5 <[email protected]>
Head branch was pushed to by a user without write access
|
The |
Related: #124829
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Bound the randomized
index_granularityandindex_granularity_bytesin the test03100_lwu_30_join_cache.Description
03100_lwu_30_join_cachetimed out in Stateless tests (arm_binary, ParallelReplicas, s3 storage, sequential): the client waited 300 s forOPTIMIZE ... FINAL. The runner's rerun reproduced it with the same draw and passed 28/28 without randomization.The MergeTree randomizer drew
index_granularity = 20withmin_bytes_for_wide_part = 1 GiB, so the three patch parts written byUPDATEwere Compact, with 150,000 granules on S3. The merge reads a compact patch part with two S3 GETs per granule: 300,038 GETs and a 558 s merge (54 GETs and 1 s without randomization).The test checks that
OPTIMIZE FINALapplies the patches, which does not depend on granularity. This adds-- Random settings limits: index_granularity=(8192, None); index_granularity_bytes=(10485760, None): granules are never finer than the defaults and stay randomized above them. A first version with floors 1000 / 100000 failed theamd_binaryflaky check at 184.87 s. That check runs under ThreadFuzzer, whereOPTIMIZEtook 169 s atindex_granularity = 1000, and 100000 bytes still cut the patch parts (44 bytes per row) into ~2,300-row granules.Validation (local, CI
amd_binarybuilds):return code 159after 300 s and 300,038 GETs, as on CI; the GET count is linear in patch granules (6,038 atindex_granularity = 1000).patch_parts_versionv2) took 431 s here, about 120 s at CI's speed.Workflow [PR]
Sync PR [sync-upstream/pr/125032]
Version info
26.11.1.1306-master(included in26.11and later)