mirror of
https://github.com/talent-plan/tinykv.git
synced 2025-03-28 21:10:23 +08:00
Add back the noop entry hint for "becomeLeader" (#148)
from master to course branch the noop entry is important hint for implementation, else learner will feel confused when test fail.
This commit is contained in:
parent
bda9f18a70
commit
a674bd7ab1
@ -196,6 +196,7 @@ func (r *Raft) becomeCandidate() {
|
||||
// becomeLeader transform this peer's state to leader
|
||||
func (r *Raft) becomeLeader() {
|
||||
// Your Code Here (2A).
|
||||
// NOTE: Leader should propose a noop entry on its term
|
||||
}
|
||||
|
||||
// Step the entrance of handle message, see `MessageType`
|
||||
|
Loading…
Reference in New Issue
Block a user