Skip to content

[python] Support conflict detection when updating existing data concurrently.#7323

Merged
JingsongLi merged 10 commits intoapache:masterfrom
discivigour:conflictDetection
Mar 3, 2026
Merged

[python] Support conflict detection when updating existing data concurrently.#7323
JingsongLi merged 10 commits intoapache:masterfrom
discivigour:conflictDetection

Conversation

@discivigour
Copy link
Contributor

Purpose

Support conflict detection when updating the data-evolution table concurrently.

Tests

API and Format

  • TableUpdateTest.test_concurrent_updates_with_retry()

Documentation

Generative AI tooling

@discivigour discivigour marked this pull request as ready for review March 3, 2026 08:08
partition: Tuple
bucket: int
new_files: List[DataFileMeta]
snapshot_for_update: int = -1
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

just check_from_snapshot? and use Option[long]

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I will rename it.

# Extract snapshot_for_update from commit messages
for msg in commit_messages:
if msg.snapshot_for_update != -1:
self.conflict_detection._row_id_check_from_snapshot = msg.snapshot_for_update
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Here should do a min computation.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ok.

Copy link
Contributor

@JingsongLi JingsongLi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

+1

@JingsongLi JingsongLi merged commit be4d1a3 into apache:master Mar 3, 2026
5 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants