Repository navigation
Add Iceberg tables from the Apache Doris tests - #130016
alexey-milovidov wants to merge 12 commits into
Conversation
Iceberg tables from the Apache Doris repository (`be/test/exec/test_data`) and from the archive of its external table regression test environment (`iceberg_data_spark40_paimon142.zip`, produced by `docker/thirdparties/docker-compose/iceberg/tools/save_docker.sh`), with the expected results of the Doris regression tests: complex types, schema evolution, partitions and transforms, Flink equality deletes, Spark position deletes, timestamp filters, and data files outside the table location. Some tests fail until the following bugs are fixed: `parquet-list-map-key`, `orc-avro-position-deletes`, `path-resolver`, a `BAD_GET` exception for decimals widened inside arrays, and empty subcolumns of arrays of structs in Iceberg Parquet tables. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
Workflow [PR], commit [b85490d] Summary: ❌
AI ReviewSummaryAdds 43 Apache Doris Iceberg fixture tables and six stateless tests covering nested types, schema evolution, partitions, deletes, timestamp filtering, and external data paths. Reviewed head Findings❌ Blockers
Tests
Final VerdictStatus: ❌ Block Resolve the fixture-storage blocker and land the four reader fixes, then demonstrate that all six added tests pass. |
…time zone in another session time zone Related: #130023 Related: #130024 Related: #130025 Co-Authored-By: Claude Opus 5.5 <[email protected]>
The `test_numbers_check` style check failed with `Gap (5567, 5720) > 100`. https://s3.amazonaws.com/clickhouse-test-reports/praktika.html?PR=130016&sha=e86dad9327fbac8055edfde0fa380bf0078a2ca7&name_0=PR&name_1=Style%20check #130016 Co-Authored-By: Claude Opus 5.5 <[email protected]>
#130000 and #130024 are fixed on master. The schema change tables are readable now, but subcolumns of the evolved struct still fail (#128304). Link the issues instead of the internal bug names. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
|
||
| - Only the latest `*.metadata.json` file of each table is kept. The older metadata versions are not used for reading | ||
| the current snapshot, and some tables have more than 30 of them (about 90 KB each). | ||
| All other files (manifest lists and manifests of the older snapshots, data and delete files) are kept as they are. |
There was a problem hiding this comment.
[Blocker] Keep the binary fixture dataset outside git
This change commits 602 Avro/Parquet/ORC files (2,502,498 bytes of binary data), with the fixture directory totaling about 3.1 MB. The review rule prohibiting binary blobs and datasets larger than 1 MB applies to this dataset; these objects permanently increase the history downloaded by every clone. Please publish the selected fixtures as a versioned, checksum-verified test artifact and fetch it during test setup, retaining the scripts, references and provenance in git.
There was a problem hiding this comment.
🕵 Not changing this. Unlike the other Iceberg fixture PRs, this one has no large file: the biggest is a 92 KB metadata.json and the biggest data file is 22 KB, so it is a set of small upstream tables kept as-is (manifests reference each other by path, so they can't be shrunk without losing the upstream expected results). The only big table of the archive (table_with_append_file, 33 MB) is already left out, see README.md. Fetching the fixtures at test time would make the stateless tests depend on network access; other data directories next to it are much larger (data_parquet 37 MB, data_delta_lake 21 MB, data_lake_corpus 24 MB). Leaving the final decision to a human reviewer.
… `05620_iceberg_doris_timestamp_filters` The single row of `tb_ts_ntz_filter` is returned by the unfiltered query, the equality, the `>` comparison with the shorter literal and the `<` comparison with the larger literal: four rows, not five. Co-Authored-By: Claude Opus 5.5 <[email protected]>
|
🕵 Merged |
… on ORC are supported now Position deletes against ORC data files were implemented in #130093 (#130001), so after merging `master` the test passes and the comment about the expected failure is stale. Co-Authored-By: Claude Fable 5.2 <[email protected]>
Adopt Iceberg tables and expected results from the Apache Doris tests (https://github.com/apache/doris/tree/41cd2b473e9d9bb26be089f302cdfdfe6e107eaf, Apache-2.0) as stateless tests. The tables were written by Spark (3.x/4.0), Flink, the Iceberg Java API and Unity Catalog (Delta UniForm).
43 tables (3.1 MB) are added to
tests/queries/0_stateless/data_iceberg/doris, from two sources (provenance inREADME.mdthere):be/: the four Iceberg tables of the Doris BE unit tests,be/test/exec/test_data(HDFS locationshdfs://hdfs-cluster/..., one with a location that differs from the directory name). Doris checks only their structure; the values in the reference were checked with PyIceberg, and the ORC and Parquet copies agree.warehouse/: tables of the Doris external table regression tests, from the archive https://doris-regression-hk.oss-cn-hongkong.aliyuncs.com/regression/datalake/pipeline_data/iceberg_data_spark40_paimon142.zip. It is downloaded bystart_icebergindocker/thirdparties/run-thirdparties-docker.shand is a snapshot of the MinIO bucket of the Doris Iceberg docker stack made bydocker/thirdparties/docker-compose/iceberg/tools/save_docker.sh. The archive is published by the Apache Doris project for its test suite but has no license file of its own. The bucket layout is kept (s3a://warehouse/...,s3://warehouse/...), including data files outside the table location (warehouse/data/...). Only the latestmetadata.jsonof each table is kept.The expected results come from
regression-test/data/external_table_p0/iceberg/*.outof the matching.groovysuites, translated to ClickHouse SQL and the ClickHouse text format. For the schema change tables, which ClickHouse can't read yet, the reference was produced with PyIceberg and checked against the Doris.out.Tests:
05616_iceberg_doris_complex_types: 5-level nested arrays, maps with array keys, deep structs (ORC and Parquet, v1 and v2); BE nested user profile tables.05617_iceberg_doris_schema_evolution: type widening (int to bigint, float to double, decimal(12,N) to decimal(20,N), also inside arrays, maps and structs), dropped, added, renamed and reordered columns and struct fields; upper case column names; column names that are not valid Avro names.05618_iceberg_doris_partitions: identity partitions on upper and lower case columns, NULL, float and string partition values,truncate,dayon dates,day/identity/bucketon 1000 rows of all primitive types (with column statistics as in Doris).05619_iceberg_doris_deletes: Flink upsert equality deletes (with a position delete in the same commit) on one and three key columns, Spark merge-on-read position deletes over many commits, Parquet and ORC.05620_iceberg_doris_timestamp_filters:timestampandtimestamptzcomparisons with literals of different sub-second precision (min/max pruning), date and string predicates.05621_iceberg_doris_data_outside_table_location: data files outside the table location, added with the Java API, and a Delta UniForm table with physical column names.Must be merged after the fixes of:
Related: #129990
Related: #130023
Related: #130025
Related: #128304
Until then, these tests fail:
05616_iceberg_doris_complex_types(Iceberg Parquet: subcolumn of an array of structs (profile.hobbies.name) reads as empty arrays #130023): incomplex_user_profiles_iceberg_parquetandnested_user_profiles_iceberg_parquet, subcolumns of arrays of structs (profile.hobbies.name,friends.nickname) read as empty arrays, whilearrayMap(x -> x.name, profile.hobbies), the ORC tables andfileon the same Parquet files are correct. (Thecol3.keyParquet failure, Parquet: aLISTused as aMAPkey is read asTuple(list Array(Tuple(element ...)))instead ofArray#130000, is fixed by Read a ParquetLISTorMAPused as aMAPkey asArrayorMap#130080.)05617_iceberg_doris_schema_evolution: theBAD_GETfor a widenedarray<decimal>(Iceberg: decimal widening inside alistmakes the table unreadable (Bad get: has Decimal64, requested Decimal128) #130024) is fixed by Fix Iceberg schema evolution of decimals widened inside arrays, maps and structs #130114; now subcolumns of the evolved struct (rename_col7.add,rename_col7.x) fail withNOT_FOUND_COLUMN_IN_BLOCK(Iceberg: struct subcolumnst.xfails withNOT_FOUND_COLUMN_IN_BLOCKon data files written before any schema change #128304), while the whole struct is read correctly.05621_iceberg_doris_data_outside_table_location:multi_partition2(locations3a://warehouse/wh/test_db/multi_partition2, data filess3://warehouse/data/multi_partition2/...) fails with FILE_DOESNT_EXIST for the mangled patharehouse/data/multi_partition2/...(path-resolver, Iceberg: file paths outside the tablelocationprefix are resolved to mangled paths (file:/vsfile:///, relative locations, data outside the table directory) #129990).05620_iceberg_doris_timestamp_filters(Icebergtimestampwithout time zone is read in the session time zone: wall-clock values and filters change withsession_timezone#130025):tb_ts_ntz_filterread withsession_timezone = 'Asia/Shanghai'shows20:34:56.123456instead of the wall-clock12:34:56.123456, and equality and<filters return nothing (alsotb_ts_filterwithts = '2024-05-30 20:34:56.1').05618_iceberg_doris_partitionsand05619_iceberg_doris_deletespass now.Already fixed on master: #130000 (by #130080), #130024 (by #130114), #130001 (ORC position deletes, by #130093).
Changelog category (leave one):
🤖 Generated with Claude Code
Workflow [PR]
Sync PR [sync-upstream/pr/130016]