JingsongLi commented on PR #9244:
URL: https://github.com/apache/paimon/pull/9244#issuecomment-5311754016

   When rolling back or reusing a snapshot ID, `IcebergCommitCallback` 
preserves only the `tableUuid` and `lastColumnId` from the abandoned metadata, 
failing to retain the `nextRowId` high-water mark. Reproduction scenario: After 
a commit, `next-row-id` is 3; upon rollback and subsequent reuse of snapshot 2, 
the new snapshot actually receives `first-row-id=0`, violating the Iceberg v3 
rule that row IDs must not be reused. Root cause locations: 
`paimon-core/src/main/java/org/apache/paimon/iceberg/IcebergCommitCallback.java:341`
 and 
`paimon-core/src/main/java/org/apache/paimon/iceberg/IcebergCommitCallback.java:2014`.
 Recommendation: Pass `nextRowIdFloor` in a manner similar to 
`lastColumnIdFloor`, setting it to the maximum of the high-water marks from the 
base metadata and the abandoned/surviving metadata.


-- 
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]

Reply via email to