Skip to content

Skip prewhere_subcolumn_read_steps and lazy_final_aggregation_in_order in the Iceberg configuration of the performance tests - #129658

Merged
egor-click merged 2 commits into
ClickHouse:masterfrom
groeneai:ci/iceberg-skip-prewhere-subcolumn-read-steps
Nov 6, 2026
Merged

egor-click merged 2 commits into
ClickHouse:masterfrom
groeneai:ci/iceberg-skip-prewhere-subcolumn-read-steps

Conversation

@groeneai

@groeneai groeneai commented Nov 6, 2026 •

Copy link
Copy Markdown
Collaborator

Related: #124553
Related: #123326
Related: #128261

Changelog category (leave one):

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

Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):

The Iceberg configuration of the performance tests no longer runs prewhere_subcolumn_read_steps, which has a JSON column, and lazy_final_aggregation_in_order, which asserts the number of MergeTree parts.

Description

Since #124553 merged, the Iceberg performance jobs that run every selected test fail with one error:

IcebergRewriteError: Column `j` of type JSON(max_dynamic_paths = 0) has no Iceberg equivalent

https://s3.amazonaws.com/clickhouse-test-reports/praktika.html?PR=129495&sha=fb710e1faad881fe9668fac524890985c0bc30f5&name_0=PR&name_1=Performance%20Comparison%20%28arm_release%2C%20master_head%2C%20iceberg_local%2C%201%2F3%29

On 2026-11-05 it hit 6 PRs within 75 minutes (iceberg_local and iceberg_s3, shard 1/3). tests/performance/prewhere_subcolumn_read_steps.xml creates a JSON(max_dynamic_paths = 0) table, and the Iceberg rewrite has no mapping for JSON. The last CI run of #124553 was before #128261 started running the Iceberg jobs on the tests a PR adds, so this never ran there.

The change adds the test to tests/performance/iceberg_skip_list.txt with the reason JSON column, like prewhere_subcolumns.xml and prewhere_column_sizes_pruned_parts.xml. Its other table (bucketed Map) measures MergeTree read steps, so the test has nothing to measure on Iceberg.

Since #123326 merged, the same jobs also fail on lazy_final_aggregation_in_order (shard 3/3, both backends) with expected 2 active parts (Code 395):

https://s3.amazonaws.com/clickhouse-test-reports/praktika.html?PR=129658&sha=0dfa6a4916b39a506274260567a7b409d63c6843&name_0=PR&name_1=Performance%20Comparison%20%28arm_release%2C%20master_head%2C%20iceberg_s3%2C%203%2F3%29

Its setup checks system.parts for 2 active parts, and the rewritten Iceberg table has none. Its last CI run also predates #128261. It is added with the reason of lazy_final_early_exit_limit.xml, which has the same check.

Validation: with test_discovery.test_runs_with_table_engine, 291 tests were selected for the Iceberg configuration before the change and 289 after; the two tests above are the ones removed. None of the 289 reads system.parts or calls throwIf.


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

Version info

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

…e performance tests

The test has a `JSON(max_dynamic_paths = 0)` column, which the Iceberg
rewrite of the perf runner cannot map, so every Iceberg perf job that
selects it fails with `IcebergRewriteError: Column j of type JSON(...)
has no Iceberg equivalent` (6 PRs on 2026-11-05). It came from ClickHouse#124553,
whose last CI run predates the Iceberg jobs running on the tests a PR
adds (ClickHouse#128261), so it was never run in this configuration.

Add it to the skip list with the reason `JSON column`, like
prewhere_subcolumns.xml. Its other table (bucketed Map) measures a
MergeTree-only PREWHERE read-step behaviour, so there is nothing to
measure on Iceberg.

Validated with test_discovery.test_runs_with_table_engine: 291 tests
selected before, 290 after (this one removed).

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

groeneai commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator Author
Internal second-model review: adjudication log (click to expand)

Pre-publication review by an independent model (engine: codex; 0 findings) plus my own cold review (0 findings).

No findings to adjudicate.

Session id: cron:clickhouse-review-slot-8:20261106-010200

@groeneai

groeneai commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator Author
Pre-PR validation gate (click to expand)
# Question Answer
a Deterministic repro? Yes. The Iceberg test selector (test_discovery.test_runs_with_table_engine) selects prewhere_subcolumn_read_steps.xml on master c8c7411269eb; every CI run that selected it errored (22 of 22, 6 PRs).
b Root cause explained? The test creates a JSON(max_dynamic_paths = 0) column; the Iceberg rewrite has no Iceberg type for JSON and raises IcebergRewriteError for the whole test, which perf.py reports as the job error.
c Fix matches root cause? Yes. The test cannot run on Iceberg tables, and the skip list with a reason is the opt-out the README prescribes (as for prewhere_subcolumns.xml).
d Test intent preserved / new tests added? Yes. MergeTree perf runs of the test are unchanged. Test-infrastructure change, so no new test; validated locally.
e Both directions demonstrated? Yes. Selector before: selected, 291 tests; after: not selected, 290 tests.
f Fix is general across code paths? Yes. Both selection paths (all tests, and tests a PR changes) read the same skip list. No other test errors in more than one PR.
g Fix generalizes across inputs (params/datatypes/wrappers)? N/A (test selection list). Applies to both iceberg_local and iceberg_s3.
h Backward compatible? (maintainer-approved exception only) N/A (CI-only change).
i Invariants and contracts preserved? Yes. The list stays C-sorted, # aligned at column 58, every entry names an existing test.

Session id: cron:clickhouse-impl-slot-7:20261106-005600

@groeneai

groeneai commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator Author

cc @egor-click, could you review this and add the can be tested label so CI runs? It adds prewhere_subcolumn_read_steps.xml to tests/performance/iceberg_skip_list.txt: its JSON column has no Iceberg equivalent, so the Iceberg performance jobs (iceberg_local, iceberg_s3) that select it fail on every PR.

@clickhouse-gh

clickhouse-gh Bot commented Nov 6, 2026 •

Copy link
Copy Markdown
Contributor

Workflow [PR], commit [2527729]

Summary: ✅


AI Review

Summary

PR #129658, reviewed at 2527729e59dcf1ba852b20fe6799bc083a5ace2e, excludes two incompatible tests from the Iceberg performance configuration: prewhere_subcolumn_read_steps.xml requires unsupported JSON columns, and lazy_final_aggregation_in_order.xml asserts MergeTree part counts through system.parts. No actionable findings. Focused validation confirmed selection drops from 291 to 289 tests, excludes exactly these files, and retains both in regular discovery. The JSON rewrite exception reproduces for both backends. Full performance jobs were not rerun locally.

Final Verdict

✅ Approve. No required changes or new inline findings.

@groeneai

groeneai commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator Author

CI finish ledger - 0dfa6a4

Every failure below has an owner: a fixing PR (mine or external), or a full-effort fix task
whose fixing-PR link will be posted here when it opens. Only CH Inc sync is exempt.

Check / test Reason Owner / fixing PR
Performance Comparison (arm_release, master_head, iceberg_local, 3/3) and (arm_release, master_head, iceberg_s3, 3/3) / lazy_final_aggregation_in_order not from this PR's diff: the one error of each shard is that test's fill query throwIf(count() != 2, ...) over system.parts (expected 2 active parts), which has no rows for the Iceberg table the runner creates instead of the ReplacingMergeTree. The test is not in tests/performance/iceberg_skip_list.txt; the same error failed the same shards on 1 other PR today a fix task is created (investigating at full effort, fixing-PR link to follow here)
PR praktika rollup of the row above a fix task is created (the same task as the row above)

Shards 1/3 and 2/3 of both Iceberg configurations pass on this head, and no shard reports the prewhere_subcolumn_read_steps error any more. The slower marks on minmax_count_projection_plan_time in the iceberg_s3, 3/3 shard do not fail it. The Config Workflow / Pre Hooks failures in CIDB come from the runs before the can be tested label and are superseded by this run.

Session id: cron:our-pr-ci-monitor:20261106-040003

…the performance tests

The setup of the test asserts two active parts with
`throwIf(count() != 2) FROM system.parts`. The Iceberg configuration
rewrites its ReplacingMergeTree table to IcebergLocal/IcebergS3, which
has no rows in `system.parts`, so the setup fails with Code 395
("expected 2 active parts") and so does the whole Iceberg perf shard.

The test came with ClickHouse#123326, whose last CI run (2026-10-26) predates
ClickHouse#128261, which started running the Iceberg jobs on the tests a PR adds,
so it never ran in this configuration before it reached master.

The reason is the one of lazy_final_early_exit_limit.xml,
lazy_materialization_final_limit.xml and read_in_reverse_order_final.xml,
which have the same check over `system.parts` plus FINAL.

Co-Authored-By: Claude Opus 5.5 <[email protected]>
@groeneai groeneai changed the title Skip prewhere_subcolumn_read_steps in the Iceberg configuration of the performance tests Skip prewhere_subcolumn_read_steps and lazy_final_aggregation_in_order in the Iceberg configuration of the performance tests Nov 6, 2026
@groeneai

groeneai commented Nov 6, 2026

Copy link
Copy Markdown
Collaborator Author
Internal second-model review: adjudication log (click to expand)

Pre-publication review of 2527729 by an independent model (engine: codex) and my own cold review: 0 findings.

Session id: cron:clickhouse-review-slot-8:20261106-050900

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

can be tested Allows running workflows for external contributors 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