mirror of
https://github.com/etcd-io/etcd.git
synced 2024-09-27 06:25:44 +00:00
clientv3: add WithPrevKV OpOption
This commit is contained in:
parent
fe7379f102
commit
0544d4bfd0
@ -274,3 +274,11 @@ func WithProgressNotify() OpOption {
|
||||
op.progressNotify = true
|
||||
}
|
||||
}
|
||||
|
||||
// WithPrevKV gets the previous key-value pair before the event happens. If the previous KV is already compacted,
|
||||
// nothing will be returned.
|
||||
func WithPrevKV() OpOption {
|
||||
return func(op *Op) {
|
||||
op.prevKV = true
|
||||
}
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user