added etcd kv
This commit is contained in:
parent
ce7d138c60
commit
fd9f8fc1fd
8 changed files with 54 additions and 71 deletions
|
|
@ -15,7 +15,7 @@ type Cluster interface {
|
|||
}
|
||||
|
||||
type KV interface {
|
||||
Get(k string) []byte
|
||||
Get(k string) ([]byte, error)
|
||||
Set(k string, v []byte) error
|
||||
Delete(k string) error
|
||||
}
|
||||
|
|
@ -29,4 +29,5 @@ type CallbackContext interface {
|
|||
type Callbacks struct {
|
||||
Leader func(context.Context, CallbackContext)
|
||||
Follower func(context.Context, CallbackContext)
|
||||
Cleanup func(context.Context, CallbackContext)
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue