-
Notifications
You must be signed in to change notification settings - Fork 549
fix: retry advancement of PreparedCommit into PostCommit in case version 0 already exists (created by another writer)
#3513
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
base: main
Are you sure you want to change the base?
Conversation
|
ACTION NEEDED delta-rs follows the Conventional Commits specification for release automation. The PR title and description are used as the merge commit message. Please update your PR title and description to match the specification. |
PreparedCommit into PostCommit in case version 0 has been created (by another writer)PreparedCommit into PostCommit in case version 0 has been created (by another writer)
|
@danielgafni do git commit -m "msg" -s |
Codecov Report❌ Patch coverage is
Additional details and impacted files@@ Coverage Diff @@
## main #3513 +/- ##
===========================================
+ Coverage 26.24% 74.08% +47.84%
===========================================
Files 124 152 +28
Lines 19824 39601 +19777
Branches 19824 39601 +19777
===========================================
+ Hits 5203 29340 +24137
+ Misses 14251 8933 -5318
- Partials 370 1328 +958 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
| }?; | ||
| } | ||
|
|
||
| // unwrap() is safe here due to the above check |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to also load the snapshot now when VersionAlreadyExists was thrown the first time in it's current state this will panic.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Uhh right. Done.
Can we test this? Seems tricky since we'd have to perfectly time writing the 0 version from another writer.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Should we also initialize attempt_number to 2 in this case?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Would be easier to test in Rust
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Can you add a test for this please? There are some concurrency tests, somewhere in the rust codebase which you can use as template
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'll look into that. A more direct pointer would be appreciated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
delta-rs/crates/test/src/concurrent.rs here you can find some related stuff
|
@ion-elgreco I do have commit signing enabled by default, and GitHub recognizes them as well (see the green Edit: actually this is the case --- the |
cf61e65 to
98605fc
Compare
PreparedCommit into PostCommit in case version 0 has been created (by another writer)PreparedCommit into PostCommit in case version 0 already exists (created by another writer)
98605fc to
4ed550b
Compare
c80dad3 to
7cad22f
Compare
|
@ion-elgreco could you please take another look? |
7cad22f to
c0d9c59
Compare
Signed-off-by: danielgafni <[email protected]>
c0d9c59 to
706e131
Compare

Description
This PR fixes the
PreparedCommitto fallback to the retry mechanism in case version 0 has been created by another writer.Related Issue(s)
Resolve #3505