mirror of
https://github.com/status-im/consul.git
synced 2025-01-09 21:35:52 +00:00
Handle new Raft API
This commit is contained in:
parent
29fe144b5b
commit
1e3adb54f3
@ -42,7 +42,8 @@ func (c *consulFSM) State() *StateStore {
|
|||||||
return c.state
|
return c.state
|
||||||
}
|
}
|
||||||
|
|
||||||
func (c *consulFSM) Apply(buf []byte) interface{} {
|
func (c *consulFSM) Apply(log *raft.Log) interface{} {
|
||||||
|
buf := log.Data
|
||||||
switch structs.MessageType(buf[0]) {
|
switch structs.MessageType(buf[0]) {
|
||||||
case structs.RegisterRequestType:
|
case structs.RegisterRequestType:
|
||||||
return c.applyRegister(buf[1:])
|
return c.applyRegister(buf[1:])
|
||||||
|
Loading…
x
Reference in New Issue
Block a user