raft: add Status interface
Status returns the current status of raft state machine.
This commit is contained in:
@ -1300,15 +1300,18 @@ func (n *nodeRecorder) Step(ctx context.Context, msg raftpb.Message) error {
|
||||
n.Record(testutil.Action{Name: "Step"})
|
||||
return nil
|
||||
}
|
||||
func (n *nodeRecorder) Status() raft.Status { return raft.Status{} }
|
||||
func (n *nodeRecorder) Ready() <-chan raft.Ready { return nil }
|
||||
func (n *nodeRecorder) Advance() {}
|
||||
func (n *nodeRecorder) ApplyConfChange(conf raftpb.ConfChange) *raftpb.ConfState {
|
||||
n.Record(testutil.Action{Name: "ApplyConfChange", Params: []interface{}{conf}})
|
||||
return &raftpb.ConfState{}
|
||||
}
|
||||
|
||||
func (n *nodeRecorder) Stop() {
|
||||
n.Record(testutil.Action{Name: "Stop"})
|
||||
}
|
||||
|
||||
func (n *nodeRecorder) Compact(index uint64, nodes []uint64, d []byte) {
|
||||
n.Record(testutil.Action{Name: "Compact"})
|
||||
}
|
||||
|
Reference in New Issue
Block a user