Handle new Raft API

This commit is contained in:
Armon Dadgar 2014-01-03 17:15:09 -08:00
parent 29fe144b5b
commit 1e3adb54f3
1 changed files with 2 additions and 1 deletions

View File

@ -42,7 +42,8 @@ func (c *consulFSM) State() *StateStore {
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]) {
case structs.RegisterRequestType:
return c.applyRegister(buf[1:])