Repository navigation
Add IcebergLocal performance tests - #116065
Conversation
|
Workflow [PR], commit [a43c2d6] Summary: ✅
AI ReviewSummaryThis PR wires a new shared Findings
Final Verdict |
| </create_query> | ||
|
|
||
| <fill_query> | ||
| INSERT INTO iceberg_suite_lineitem SELECT * FROM tpch10.lineitem |
There was a problem hiding this comment.
I think we need more tables, because it's useful to also check the cases when:
- we have one/many data files per manifest file
- we have one/many manifest files per manifest list
There was a problem hiding this comment.
sure, this is just a proto - wanna see the new reports, and profiling data. Will ping you once it's more or less ready
There was a problem hiding this comment.
it's done in rw_features.xml tests now
There was a problem hiding this comment.
The new manifest_grid block still does not cover the "many data files per manifest" half of this. Each INSERT ... LIMIT 50000 ... iceberg_insert_max_rows_in_data_file = 10000 at tests/performance/iceberg_suite_rw_features.xml:157-168 is a single 50K-row chunk, and MultipleFileWriter::consume only rotates before the next incoming chunk (src/Storages/ObjectStorage/DataLakes/Iceberg/MultipleFileWriter.cpp:70-79). So each commit still produces one data file and one manifest entry; the added cases cover many manifests, but not many entries per manifest.
Build profile diff (arm_release)Comparing ✅ No significant changes. Binary sizes
The official master build is compiled with Object file sizes8 object files changed (+48.79 KiB total), 0 added.
716 more object files are built by the master warmup baseline only (it builds every object-file target, a pull request build only Compile time of recompiled translation units8 translation units recompiled, 29 s compile time in total, 8 of them have a recent master baseline. |
cce01f8 to
e074825
Compare
In CI, `perf.py` runs only 10 random queries of each test (`--max-queries 10`), except for a hardcoded filename allowlist of whole-suite benchmarks in `ci/jobs/performance_tests.py`. Replace the allowlist with a per-test root attribute `<test run_all_queries="1">`, parsed by `perf.py` itself: the property now lives in the test file, survives renames, and applies to any invocation, not only the CI wrapper. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
Add the TPC-H SF10 `IcebergLocal` dataset and a TPC-H suite over it (`iceberg_suite_tpch.xml`: the 22 queries of `tpch.xml`, unchanged, against Iceberg tables), and register the dataset in both consumers of `tests/performance/*.xml`: - the performance-comparison job downloads the tarball and attaches the `tpch_ice10` database on both servers; - the PGO/BOLT profile-collection job does the same for its single server, so the Iceberg suites contribute coverage to the collected profiles instead of failing on a missing database. The dataset catalog `ICEBERG_DATASETS` and the DDL generator `iceberg_database_ddl_commands` live in `ci/jobs/scripts/dataset_download.py`, shared by both jobs. The DDL cannot ship in the tarball because `IcebergLocal` stores an absolute path that differs per server. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
93c05de to
179d7a6
Compare
In CI, `perf.py` runs only 10 random queries of each test (`--max-queries 10`), except for a hardcoded filename allowlist of whole-suite benchmarks in `ci/jobs/performance_tests.py`. Replace the allowlist with a per-test root attribute `<test run_all_queries="1">`, parsed by `perf.py` itself: the property now lives in the test file, survives renames, and applies to any invocation, not only the CI wrapper. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
Add the TPC-H SF10 `IcebergLocal` dataset and a TPC-H suite over it (`iceberg_suite_tpch.xml`: the 22 queries of `tpch.xml`, unchanged, against Iceberg tables), and register the dataset in both consumers of `tests/performance/*.xml`: - the performance-comparison job downloads the tarball and attaches the `tpch_ice10` database on both servers; - the PGO/BOLT profile-collection job does the same for its single server, so the Iceberg suites contribute coverage to the collected profiles instead of failing on a missing database. The dataset catalog `ICEBERG_DATASETS` and the DDL generator `iceberg_database_ddl_commands` live in `ci/jobs/scripts/dataset_download.py`, shared by both jobs. The DDL cannot ship in the tarball because `IcebergLocal` stores an absolute path that differs per server. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
In CI, `perf.py` runs only 10 random queries of each test (`--max-queries 10`), except for a hardcoded filename allowlist of whole-suite benchmarks in `ci/jobs/performance_tests.py`. Replace the allowlist with a per-test root attribute `<test run_all_queries="1">`, parsed by `perf.py` itself: the property now lives in the test file, survives renames, and applies to any invocation, not only the CI wrapper. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
Add the TPC-H SF10 `IcebergLocal` dataset and a TPC-H suite over it (`iceberg_suite_tpch.xml`: the 22 queries of `tpch.xml`, unchanged, against Iceberg tables), and register the dataset in both consumers of `tests/performance/*.xml`: - the performance-comparison job downloads the tarball and attaches the `tpch_ice10` database on both servers; - the PGO/BOLT profile-collection job does the same for its single server, so the Iceberg suites contribute coverage to the collected profiles instead of failing on a missing database. The dataset catalog `ICEBERG_DATASETS` and the DDL generator `iceberg_database_ddl_commands` live in `ci/jobs/scripts/dataset_download.py`, shared by both jobs. The DDL cannot ship in the tarball because `IcebergLocal` stores an absolute path that differs per server. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
179d7a6 to
6c1004c
Compare
6c1004c to
07e63a1
Compare
In CI, `perf.py` runs only 10 random queries of each test (`--max-queries 10`), except for a hardcoded filename allowlist of whole-suite benchmarks in `ci/jobs/performance_tests.py`. Replace the allowlist with a per-test root attribute `<test run_all_queries="1">`, parsed by `perf.py` itself: the property now lives in the test file, survives renames, and applies to any invocation, not only the CI wrapper. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
Add the TPC-H SF10 `IcebergLocal` dataset and a TPC-H suite over it (`iceberg_suite_tpch.xml`: the 22 queries of `tpch.xml`, unchanged, against Iceberg tables), and register the dataset in both consumers of `tests/performance/*.xml`: - the performance-comparison job downloads the tarball and attaches the `tpch_ice10` database on both servers; - the PGO/BOLT profile-collection job does the same for its single server, so the Iceberg suites contribute coverage to the collected profiles instead of failing on a missing database. The dataset catalog `ICEBERG_DATASETS` and the DDL generator `iceberg_database_ddl_commands` live in `ci/jobs/scripts/dataset_download.py`, shared by both jobs. The DDL cannot ship in the tarball because `IcebergLocal` stores an absolute path that differs per server. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
In CI, `perf.py` runs only 10 random queries of each test (`--max-queries 10`), except for a hardcoded filename allowlist of whole-suite benchmarks in `ci/jobs/performance_tests.py`. Replace the allowlist with a per-test root attribute `<test run_all_queries="1">`, parsed by `perf.py` itself: the property now lives in the test file, survives renames, and applies to any invocation, not only the CI wrapper. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
07e63a1 to
ef675d1
Compare
Add the TPC-H SF10 `IcebergLocal` dataset and a TPC-H suite over it (`iceberg_suite_tpch.xml`: the 22 queries of `tpch.xml`, unchanged, against Iceberg tables), and register the dataset in both consumers of `tests/performance/*.xml`: - the performance-comparison job downloads the tarball and attaches the `tpch_ice10` database on both servers; - the PGO/BOLT profile-collection job does the same for its single server, so the Iceberg suites contribute coverage to the collected profiles instead of failing on a missing database. The dataset catalog `ICEBERG_DATASETS` and the DDL generator `iceberg_database_ddl_commands` live in `ci/jobs/scripts/dataset_download.py`, shared by both jobs. The DDL cannot ship in the tarball because `IcebergLocal` stores an absolute path that differs per server. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
| <create_query>DROP TABLE IF EXISTS {database}.upd_part</create_query> | ||
| <create_query>CREATE TABLE {database}.upd_part (l_orderkey Int32, l_returnflag String, l_quantity Float64) ENGINE = IcebergLocal((SELECT value FROM system.server_settings WHERE name = 'user_files_path') || '/upd_part_' || toString(toUnixTimestamp64Micro(now64(6))) || '/', 'Parquet') PARTITION BY (l_returnflag)</create_query> | ||
| <create_query>INSERT INTO {database}.upd_part SELECT l_orderkey, l_returnflag, l_quantity FROM tpch10.lineitem LIMIT 200000 SETTINGS max_threads = 1, max_insert_threads = 1</create_query> | ||
| <query>ALTER TABLE {database}.upd_part UPDATE l_returnflag = 'X' WHERE l_orderkey % 5 = 0</query> |
There was a problem hiding this comment.
perf.py prewarms every query once before it starts timing measured runs (tests/performance/scripts/perf.py, lines 890-940). For this case the prewarm already rewrites the l_orderkey % 5 = 0 rows and moves them into partition X, so the timed runs no longer exercise the cross-partition move the comment claims to benchmark. They only measure the follow-up same-value update on already-moved rows. This needs a per-run recreate/reset or a harness that does its setup inside the timed unit.
c7487ef to
780ae98
Compare
In CI, `perf.py` runs only 10 random queries of each test (`--max-queries 10`), except for a hardcoded filename allowlist of whole-suite benchmarks in `ci/jobs/performance_tests.py`. Replace the allowlist with a per-test root attribute `<test run_all_queries="1">`, parsed by `perf.py` itself: the property now lives in the test file, survives renames, and applies to any invocation, not only the CI wrapper. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
Add the TPC-H SF10 `IcebergLocal` dataset and a TPC-H suite over it (`iceberg_suite_tpch.xml`: the 22 queries of `tpch.xml`, unchanged, against Iceberg tables), and register the dataset in both consumers of `tests/performance/*.xml`: - the performance-comparison job downloads the tarball and attaches the `tpch_ice10` database on both servers; - the PGO/BOLT profile-collection job does the same for its single server, so the Iceberg suites contribute coverage to the collected profiles instead of failing on a missing database. The dataset catalog `ICEBERG_DATASETS` and the DDL generator `iceberg_database_ddl_commands` live in `ci/jobs/scripts/dataset_download.py`, shared by both jobs. The DDL cannot ship in the tarball because `IcebergLocal` stores an absolute path that differs per server. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
| <test profile_all_queries="1" run_all_queries="1"> | ||
| <settings> | ||
| <allow_insert_into_iceberg>1</allow_insert_into_iceberg> | ||
| <mutations_sync>2</mutations_sync> |
There was a problem hiding this comment.
nice catch, thanks, I didn't know it's redundant in this case
| <!-- minmax_secondary_column: filter the non-partition l_receiptdate with partition pruning off, so only per-file min/max stats can skip files. --> | ||
| <query>SELECT count(), sum(l_quantity) FROM {database}.lineitem WHERE l_receiptdate = toDate('1994-06-15') SETTINGS use_iceberg_partition_pruning = 0</query> | ||
|
|
||
| <!-- prune_negative_control: predicate spans every file's range, nothing prunes, so the walk over all manifest entries is paid every run. --> |
There was a problem hiding this comment.
We also need a table with pruning by those stats in the manifest list(https://github.com/ClickHouse/ClickHouse/blob/master/src/Storages/ObjectStorage/DataLakes/Iceberg/AvroSchema.h#L67), and without pruning by stats in the manifest entries: https://github.com/ClickHouse/ClickHouse/blob/master/src/Storages/ObjectStorage/DataLakes/Iceberg/AvroSchema.h#L322
There was a problem hiding this comment.
And do we have any query that can show performance improvement on parallel manifest decoding?
There was a problem hiding this comment.
Thanks, I just added few new scenarios to rw_features.xml - b827fe2
it should cover these
Add the TPC-H SF10 `IcebergLocal` dataset and a TPC-H suite over it (`iceberg_suite_tpch.xml`: the 22 queries of `tpch.xml`, unchanged, against Iceberg tables), and register the dataset in both consumers of `tests/performance/*.xml`: - the performance-comparison job downloads the tarball and attaches the `tpch_ice10` database on both servers; - the PGO/BOLT profile-collection job does the same for its single server, so the Iceberg suites contribute coverage to the collected profiles instead of failing on a missing database. The dataset catalog `ICEBERG_DATASETS` and the DDL generator `iceberg_database_ddl_commands` live in `ci/jobs/scripts/dataset_download.py`, shared by both jobs. The DDL cannot ship in the tarball because `IcebergLocal` stores an absolute path that differs per server. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
Add three Iceberg performance suites over the shipped tpch_ice10 dataset: - iceberg_suite_read.xml: the read-path aspects the TPC-H scans cannot isolate - metadata cost, the pruning layers, PREWHERE, in-file push-down, parallelism, table resolution and time travel. - iceberg_suite_write.xml: a single-table pipeline exercising insert, many small commits, compaction, mutations, schema evolution, position deletes and manifest optimization; the small-commit batch lives in write_small_commits.sql. - iceberg_suite_rw_features.xml: per-feature tables for schema-evolution reads, hidden-partition transforms and pruning, sort order plus min/max, nested types and many-small-files. Every scenario comment is a single line.
Twelve single-partition commits of five files each: a detector for manifest-list partition-summary pruning (the summary is written but not yet read for skipping) and a serial-vs-parallel `iceberg_manifest_decode_concurrency` pair. Related: #116065 (comment) Related: #116065 (comment) Related: #116065 (comment)
780ae98 to
b827fe2
Compare
| <!-- manifest_grid: twelve single-partition commits of five data files each - many manifests, many entries per manifest. --> | ||
| <create_query>DROP TABLE IF EXISTS {database}.manifest_grid</create_query> | ||
| <create_query>CREATE TABLE {database}.manifest_grid (l_orderkey Int32, l_quantity Float64, l_month Int32) ENGINE = IcebergLocal((SELECT value FROM system.server_settings WHERE name = 'user_files_path') || '/manifest_grid_' || toString(toUnixTimestamp64Micro(now64(6))) || '/', 'Parquet') PARTITION BY (l_month)</create_query> | ||
| <create_query>INSERT INTO {database}.manifest_grid SELECT l_orderkey, l_quantity, 199401 AS l_month FROM tpch10.lineitem LIMIT 0, 50000 SETTINGS max_threads = 1, max_insert_threads = 1, iceberg_insert_max_rows_in_data_file = 10000</create_query> |
There was a problem hiding this comment.
iceberg_insert_max_rows_in_data_file still does not shape this table the way the comment claims. MultipleFileWriter::consume only rolls over before the next incoming chunk; it never splits a chunk mid-file. With LIMIT 50000 and no matching max_block_size / min_insert_block_size_* cap, each tpch10.lineitem insert here is a single 50K-row chunk, so every commit still produces one file, not five 10K-row files.
That means manifest_grid covers "many manifests", but not the new "many entries per manifest" case this block was added for. The same root cause also leaves update_every_file above as a one-file rewrite instead of the advertised three-file case. Please cap the source blocks too, or seed this table with a helper that emits 10K-row chunks.
In CI, `perf.py` runs only 10 random queries of each test (`--max-queries 10`), except for a hardcoded filename allowlist of whole-suite benchmarks in `ci/jobs/performance_tests.py`. Replace the allowlist with a per-test root attribute `<test run_all_queries="1">`, parsed by `perf.py` itself: the property now lives in the test file, survives renames, and applies to any invocation, not only the CI wrapper. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
In CI, `perf.py` runs only 10 random queries of each test (`--max-queries 10`), except for a hardcoded filename allowlist of whole-suite benchmarks in `ci/jobs/performance_tests.py`. Replace the allowlist with a per-test root attribute `<test run_all_queries="1">`, parsed by `perf.py` itself: the property now lives in the test file, survives renames, and applies to any invocation, not only the CI wrapper. #116065 (comment) Co-Authored-By: Claude Fable 5 <[email protected]>
scanhex12
left a comment
There was a problem hiding this comment.
looks good, maybe I'll come up with new ideas what to test later, but right now seems good
| <create_query>INSERT INTO {database}.del_pos SELECT l_orderkey, l_quantity FROM tpch10.lineitem LIMIT 50000 SETTINGS max_threads = 1, max_insert_threads = 1</create_query> | ||
| <query>ALTER TABLE {database}.del_pos DELETE WHERE l_orderkey % 7 = 0</query> | ||
|
|
||
| <!-- mor_read_position_deletes_roaring: position deletes are written at setup, so every run is a full roaring-bitmap merge-on-read scan over fixed state. --> |
There was a problem hiding this comment.
can we test also the streaming path of position deletes?
There was a problem hiding this comment.
thanks, done as the query below
| "hits1": "https://clickhouse-datasets.s3.amazonaws.com/hits/partitions/hits_v1.tar", | ||
| "values": "https://clickhouse-datasets.s3.amazonaws.com/values_with_expressions/partitions/test_values.tar", | ||
| "tpch10": "https://clickhouse-datasets.s3.amazonaws.com/h/10/tpch_sf10.tar", | ||
| "tpch_ice10": "https://clickhouse-datasets.s3.amazonaws.com/h-ice/10/tpch_ice_sf10.tar", |
There was a problem hiding this comment.
download_datasets still treats db0/.done as "all required tarballs are already present". On a reused ci/tmp/perf_wd from before this PR, that marker suppresses the new tpch_ice10 download, but Configure now always attaches tpch_ice10, so the first tpch_ice10.* query fails on a missing user_files/tpch_ice_sf10 path. ci/jobs/collect_clickhouse_profiles.py has the same early-return logic for the same new tarball. Please version the marker by the dataset set/URLs, or at least verify that the expected Iceberg directory exists before returning early.
Performance tests for
IcebergLocal:tpch_ice10(traditional tpch sf10 pre-stored in Iceberg format)tpch_ice10dataset to benchmark read featuresChangelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Add
IcebergLocalperformance tests covering read, insert and mutation paths.Workflow [PR]
Sync PR [sync-upstream/pr/116065]