feat(flink): enable LSM reader for Flink metadata table - #19373
Conversation
8a4099f to
5691ca3
Compare
5691ca3 to
8097332
Compare
8097332 to
e70f800
Compare
hudi-agent
left a comment
There was a problem hiding this comment.
Thanks for working on this! This PR enables the LSM storage layout and HoodieLsmFileGroupReader for newly created Flink v10+ metadata tables, falling back to the classic reader for reuse/mixed/legacy slices. One edge case around instant-range filtering on the LSM read path is worth a close look in the inline comment before this lands. Please take a look at any inline comments, and this should be ready for a Hudi committer or PMC member to take it from here. One minor duplication nit in the reader branch; everything else is clean.
hudi-agent
left a comment
There was a problem hiding this comment.
Thanks for working on this! The PR enables the LSM storage layout and HoodieLsmFileGroupReader for new Flink v10+ metadata tables, adds instant-range filtering of native log files, and centralizes reader selection in HoodieBackedTableMetadata. One correctness concern worth double-checking is flagged inline around how the LSM reader honors the key/prefix filter for native log records on point/prefix-lookup partitions. Please take a look at the inline comment, and this should be ready for a Hudi committer or PMC member to take it from here.
Describe the issue this Pull Request addresses
Flink metadata tables did not use the LSM-tree storage layout or
HoodieLsmFileGroupReader, missing the sorted-run merge benefits available for native log file slices.This change enables LSM storage and reads for newly created Flink v10+ metadata tables while preserving classic reader behavior for legacy/mixed log slices and reusable-buffer workloads.
Fixes #19372.
Summary and Changelog
lsm_treestorage layout.HoodieLsmFileGroupReaderfor LSM file slices containing only native logs.HoodieFileGroupReaderfor default layouts, mixed/legacy log slices, and reusable log-record buffer scenarios.Impact
HoodieBackedTableMetadata.Risk Level
Medium. This changes the storage layout and read path for new Flink v10+ metadata tables. The risk is mitigated by fallback to the classic reader for legacy, mixed-log, and reuse scenarios, with tests covering layout initialization, native logs, metadata reads, and compaction upgrade compatibility.
Documentation Update
none
Contributor's checklist