test(clickhouse): measure automatically selected SUM and MAX plans - #629
Merged
Merged
Conversation
zzylol
marked this pull request as ready for review
September 11, 2026 02:03
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
The previous ClickHouse benefit probe supplied a MinMax catalog, so it did not demonstrate automatic materialization selection. This change sends only SQL/schema/accuracy/time bounds through the real Planner and control-plane catalog builder, records the selected DAG and candidate trace, and exercises the installed state through a separate backend process.
Before: the bounded MAX measurement used a predeclared winning family. After: both SUM and MAX probes use automatically selected materializations, and a stdin example exposes the same publication/trace for independent inspection. Six controlled trials cover 6,000 warm and 6,000 exact requests with identical numeric results. Median repeated-query speedup is 5.51–8.01x for SUM and 7.87–8.88x for MAX; the report includes CPU, backfill, first-query, RSS and storage observations plus raw-trace hashes and runtime budgets.
These are bounded single-series aggregate sensitivity results, not original 27-query workload coverage. The deployment retains ClickHouse, so combined memory/storage are not lower. Construction costs, mismatched retained durations, unavailable estimated costs and a failed quantile frontend probe are stated explicitly.
Verification: release builds, a real automatic SUM process smoke test, six matched two-CPU/4-GiB process trials (1,000 warm plus 1,000 exact requests each), and
bash -nfor the reproduction runner. Runtime results identify their exact measured source/executable hashes; subsequent main replay does not change those historical measurements. Independent artifact review passed: all raw-trace hashes, request counts, numeric equality, median ratios and process budgets were checked.