yuqi1129 opened a new pull request, #12551: URL: https://github.com/apache/gravitino/pull/12551
### What changes were proposed in this pull request? - Use `current_version` as the OCC token for table alter and direct delete. - Execute the root table CAS before version, column, and dependent-row writes in one transaction. - Distinguish a concurrent version change from a deleted, renamed, or moved table. - Propagate optimistic-lock conflicts through `OperationDispatcher`. - Retry only optimistic-lock conflicts for idempotent Lance metadata repair. - Add comments explaining the transaction ordering, CAS predicates, conflict classification, and retry behavior. - Add comprehensive unit and cross-database tests. This PR depends on #12456. ### Why are the changes needed? Concurrent table writes could overwrite the winning version metadata, while a stale delete could remove data belonging to a newer table version. Some optimistic-lock conflicts were also swallowed or treated as generic IO failures. Fix: #12345 ### Does this PR introduce _any_ user-facing change? Stale managed-table writes now fail with the existing optimistic-lock conflict response instead of silently overwriting newer metadata. No API or property is added. ### How was this patch tested? - Ran 48 `TableMetaService` cases across H2, MySQL, and PostgreSQL. - Ran all 16 `TestTableOperationDispatcher` tests. - Ran 4 SQL provider OCC tests. - Ran 27 Lance table and concurrent-repair tests. - Ran Spotless and `git diff --check`. -- 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]
