jerry-024 commented on PR #252: URL: https://github.com/apache/paimon-rust/pull/252#issuecomment-4258219517
I found two behavior-compatibility issues compared with Java's postpone-bucket implementation: 1. In `crates/paimon/src/table/table_write.rs`, postpone files are always named with `...-s-0-w-...`. This is not compatible with Java. Java assigns a distinct `writeId` per writer and encodes it in the file name; the postpone compaction path later parses that `writeId` and keeps files from the same writer on the same reader so replay order matches writer-local production order. Hard-coding `s-0` removes that writer boundary entirely. Once multiple writers produce files for the same postpone partition, compaction / replay can no longer reconstruct the ordering assumptions used by Java, so conflicting PK records may resolve differently. 2. In `crates/paimon/src/table/postpone_file_writer.rs`, rolled files are closed asynchronously and `creation_time` is assigned with `Utc::now()` when the async close finishes. This is also incompatible with Java's ordering semantics. Java's postpone compaction sorts files by `DataFileMeta.creationTime` before replaying them, so `creationTime` is part of the effective replay-order contract. Here an earlier file can easily end up with a later `creation_time` than a later file, depending on close timing. That makes replay order nondeterministic and can again change the final result for PK conflicts. So these are not just implementation differences; they change the behavioral assumptions that Java relies on for postpone-bucket replay / compaction. -- 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]
