mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
10 lines
269 B
Go
10 lines
269 B
Go
package raft
|
|
|
|
// StateMachine is the interface for allowing the host application to save and
|
|
// recovery the state machine. This makes it possible to make snapshots
|
|
// and compact the log.
|
|
type StateMachine interface {
|
|
Save() ([]byte, error)
|
|
Recovery([]byte) error
|
|
}
|