Repository navigation
Support other formats (ORC, ...) in iceberg writes - #87277
Conversation
|
Workflow [PR], commit [40a7638] Summary: ❌
|
| @@ -268,6 +275,7 @@ FileNamesGenerator & FileNamesGenerator::operator=(const FileNamesGenerator & ot | |||
| storage_dir = other.storage_dir; | |||
| use_uuid_in_metadata = other.use_uuid_in_metadata; | |||
| compression_method = other.compression_method; | |||
| format_name = other.format_name; | |||
There was a problem hiding this comment.
Also for FileNamesGenerator::FileNamesGenerator(const FileNamesGenerator & other)?
|
67b4661 to
4ad8abc
Compare
|
I can say what is bothering me right now a bit more: |
|
We don't have documentation yet and adding test with non-existing format seems really strange |
Why, we test verbosity of CH this way (that error message is clearly understandable for a user)
#85953 - I think this PR should be easy to merge, or are there any problems I don't know about? |
d9fa41e to
40a7638
Compare
|
Hi @scanhex12 @kssenii @divanik — while reviewing this PR I found the following:
Happy to discuss — close anything that's wrong or already addressed. |
`ALTER TABLE ... DELETE` and `ALTER TABLE ... UPDATE` on Iceberg tables whose data file format is not Parquet either aborted the server (`Unexpected null _row_number` LOGICAL_ERROR on ORC) or silently corrupted the table (Avro write succeeded but produced position-delete files that the read path then rejected with `NOT_IMPLEMENTED`). Mutations write position-delete files using the table's `write_format`. The read side only accepts Parquet there (`IcebergDataObjectInfo::addPositionDeleteObject`), and the ORC/Avro write paths do not match that contract. PR ClickHouse#87277 (introducer) enabled non-Parquet table formats in `FileNamesGenerator` without gating the mutation paths. Validate the format up front with a single helper `Iceberg::validateMutationWriteFormat`. It is called from both `IcebergMetadata::checkMutationIsPossible` (early rejection during analysis) and `Iceberg::mutate` (defence in depth for any direct caller). Parquet tables continue to work; `ALTER ... ADD/DROP/MODIFY/RENAME COLUMN` are unaffected. Closes ClickHouse#102508.
`ALTER TABLE ... DELETE` and `ALTER TABLE ... UPDATE` on Iceberg tables whose data file format is not Parquet either aborted the server (`Unexpected null _row_number` LOGICAL_ERROR on ORC) or silently corrupted the table (Avro write succeeded but produced position-delete files that the read path then rejected with `NOT_IMPLEMENTED`). Mutations write position-delete files using the table's `write_format`. The read side only accepts Parquet there (`IcebergDataObjectInfo::addPositionDeleteObject`), and the ORC/Avro write paths do not match that contract. PR ClickHouse#87277 (introducer) enabled non-Parquet table formats in `FileNamesGenerator` without gating the mutation paths. Validate the format up front with a single helper `Iceberg::validateMutationWriteFormat`. It is called from both `IcebergMetadata::checkMutationIsPossible` (early rejection during analysis) and `Iceberg::mutate` (defence in depth for any direct caller). Parquet tables continue to work; `ALTER ... ADD/DROP/MODIFY/RENAME COLUMN` are unaffected. Closes ClickHouse#102508.
Changelog category (leave one):
Changelog entry (a user-readable short description of the changes that goes into CHANGELOG.md):
Support other formats (ORC, Avro) in iceberg writes. This closes #86179
Documentation entry for user-facing changes