|
|
@ -50,21 +50,21 @@ type KVOp string |
|
|
|
|
|
|
|
|
|
|
|
const ( |
|
|
|
const ( |
|
|
|
KVSet KVOp = "set" |
|
|
|
KVSet KVOp = "set" |
|
|
|
KVDelete = "delete" |
|
|
|
KVDelete KVOp = "delete" |
|
|
|
KVDeleteCAS = "delete-cas" |
|
|
|
KVDeleteCAS KVOp = "delete-cas" |
|
|
|
KVDeleteTree = "delete-tree" |
|
|
|
KVDeleteTree KVOp = "delete-tree" |
|
|
|
KVCAS = "cas" |
|
|
|
KVCAS KVOp = "cas" |
|
|
|
KVLock = "lock" |
|
|
|
KVLock KVOp = "lock" |
|
|
|
KVUnlock = "unlock" |
|
|
|
KVUnlock KVOp = "unlock" |
|
|
|
KVGet = "get" |
|
|
|
KVGet KVOp = "get" |
|
|
|
KVGetTree = "get-tree" |
|
|
|
KVGetTree KVOp = "get-tree" |
|
|
|
KVCheckSession = "check-session" |
|
|
|
KVCheckSession KVOp = "check-session" |
|
|
|
KVCheckIndex = "check-index" |
|
|
|
KVCheckIndex KVOp = "check-index" |
|
|
|
) |
|
|
|
) |
|
|
|
|
|
|
|
|
|
|
|
// KVTxnOp defines a single operation inside a transaction.
|
|
|
|
// KVTxnOp defines a single operation inside a transaction.
|
|
|
|
type KVTxnOp struct { |
|
|
|
type KVTxnOp struct { |
|
|
|
Verb string |
|
|
|
Verb KVOp |
|
|
|
Key string |
|
|
|
Key string |
|
|
|
Value []byte |
|
|
|
Value []byte |
|
|
|
Flags uint64 |
|
|
|
Flags uint64 |
|
|
|