laskoviymishka opened a new issue, #1058: URL: https://github.com/apache/iceberg-go/issues/1058
Parent: #589, follows #1049. #1049 added cardinality validation in `ReadDV` by reading the puffin blob's `cardinality` property. Java's `BitmapPositionDeleteIndex.deserializeBitmap` does the equivalent check against the manifest entry's `record_count` field (`DeleteFile.recordCount()`), not the puffin property. Both are set to the same value by Java's writer, so iceberg-go and Java agree for spec-conformant tables — but if a third-party writer sets them inconsistently (e.g. stale `record_count` after an incremental merge, fresh blob property), the two implementations would disagree on whether the DV is valid. `ReadDV` should consult both sources when each is independently available: - Manifest entry's `dvFile.Count()` when greater than zero — Java's primary source. - Puffin blob's `cardinality` property — what #1049 already reads. When both are non-zero and disagree, fail with a clear "manifest record_count N disagrees with puffin cardinality property M" error. When only one is available, use it. When neither, keep the current `slog.Warn` skip path. Cross-client interop benefit: catches writer bugs that affect manifest/footer agreement before they propagate to scans. -- This is an automated message from the Apache Git Service. To respond to the message, please log on to GitHub and use the URL above to go to the specific comment. To unsubscribe, e-mail: [email protected] For queries about this service, please contact Infrastructure at: [email protected] --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
