-
Notifications
You must be signed in to change notification settings - Fork 3.8k
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
release-22.2: batcheval: add BarrierRequest.WithLeaseAppliedIndex
#118474
Merged
erikgrinaker
merged 4 commits into
cockroachdb:release-22.2
from
erikgrinaker:backport22.2-117787-117967-117968
Feb 1, 2024
Merged
release-22.2: batcheval: add BarrierRequest.WithLeaseAppliedIndex
#118474
erikgrinaker
merged 4 commits into
cockroachdb:release-22.2
from
erikgrinaker:backport22.2-117787-117967-117968
Feb 1, 2024
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Otherwise, `BatchRequest.RequiresConsensus()` may return `false` and not submit the barrier through Raft. Similarly, `shouldWaitOnLatchesWithoutAcquiring` will return `false` so it will contend with later writes. Barriers are not used in recent releases, so this does not have any mixed-version concerns. Epic: none Release note: None
This can be used to detect whether a replica has applied the barrier command yet. Epic: none Release note: None
This only executes random `Barrier` requests, but does not verify that the barrier guarantees are actually satisfied (i.e. that all past and concurrent writes are applied before it returns). At least we get some execution coverage, and verify that it does not have negative interactions with other operations. Epic: none Release note: None
This allows a caller to wait for a replica to reach a certain lease applied index. Similar functionality elsewhere is not migrated yet, out of caution. Epic: none Release note: None
Thanks for opening a backport. Please check the backport criteria before merging:
If your backport adds new functionality, please ensure that the following additional criteria are satisfied:
Also, please add a brief release justification to the body of your PR to justify this |
blathers-crl
bot
added
the
backport
Label PR's that are backports to older release branches
label
Jan 30, 2024
rharding6373
approved these changes
Jan 30, 2024
nvanbenschoten
approved these changes
Jan 31, 2024
blathers backport staging-v22.2.18 |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
The behavior of
Barrier
differs between 22.2 and 23.1: the latter does not conflict with ongoing read requests, most likely because they drop latches before evaluation in 23.1. It does not seem particularly problematic that 22.2 has to wait for reads to complete, at least not for our purposes here, so I've just documented this and disabled the test coverage for read conflicts.There were also significant kvnemesis changes in 23.1, so the kvnemesis testing needed some adjustments.
Backport:
BarrierRequest
asisAlone
" (kvpb: markBarrierRequest
asisAlone
#117787)BarrierRequest.WithLeaseAppliedIndex
" (batcheval: addBarrierRequest.WithLeaseAppliedIndex
#117967)Replica.WaitForLeaseAppliedIndex()
" (kvserver: addReplica.WaitForLeaseAppliedIndex()
#117968)Please see individual PRs for details.
Release justification: prerequisites for backporting #117612.
/cc @cockroachdb/release