Avoid dup-append logs for committing logs#757
Draft
Besroy wants to merge 1 commit intoeBay:masterfrom
Draft
Conversation
77fb832 to
c3cd7be
Compare
This change avoid the following corner case: T1: lsn=100 is executing handle_commit T2: lsn=100 is requested to append from leader again, triggering raft_event and retrieving the existed rreq from map T3: lsn=100 committed, the rreq is removed from map and is cleared T4: during the raft_event process, the rreq has already been cleared, preventing further processing
|
Codecov ReportAttention: Patch coverage is
❗ Your organization needs to install the Codecov GitHub app to enable full functionality. Additional details and impacted files@@ Coverage Diff @@
## master #757 +/- ##
===========================================
+ Coverage 56.51% 67.42% +10.91%
===========================================
Files 108 109 +1
Lines 10300 12384 +2084
Branches 1402 1748 +346
===========================================
+ Hits 5821 8350 +2529
+ Misses 3894 3139 -755
- Partials 585 895 +310 ☔ View full report in Codecov by Sentry. 🚀 New features to boost your workflow:
|
Contributor
Author
|
This pr aims to resole a corner case, but using last_lsn/last_term rather than last_commit_lsn might be more dangerous and requires more consideration, so covert it to raft ATM. |
This file contains hidden or 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
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.
No description provided.