-
Notifications
You must be signed in to change notification settings - Fork 1
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
RaftActor shouldn't delete committed or non-conflict entries #151
Conversation
@negokaz |
38eaa66
to
f3c9552
Compare
src/main/scala/lerna/akka/entityreplication/raft/RaftMemberData.scala
Outdated
Show resolved
Hide resolved
src/main/scala/lerna/akka/entityreplication/raft/RaftMemberData.scala
Outdated
Show resolved
Hide resolved
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.
@xirc
Great!
I have reviewed the changes in main
and left some comments.
src/main/scala/lerna/akka/entityreplication/raft/model/ReplicatedLog.scala
Outdated
Show resolved
Hide resolved
src/main/scala/lerna/akka/entityreplication/raft/RaftMemberData.scala
Outdated
Show resolved
Hide resolved
fb4ce14
to
f8e952b
Compare
A caller should give valid entries.
040c577
to
b744b98
Compare
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.
Awesome! LGTM 👍
Closes #152
There might be two places to be able to fix this bug:
AppendedEntries
replay orAppendEntries
handlingThis PR changes
AppendEntries
handling to fix this bug.pros:
TODO
RaftMemberData.resolveNewLogEntries
ReplicatedLog.findConflict
ReplicatedLog.truncateAndAppend
AppendEntries
RaftActor
can read oldAppenddedEntries
event