Merge 3fc47ff1df
into 88fce6a140
This commit is contained in:
commit
8ab677db22
|
@ -15,13 +15,15 @@ package lock
|
|||
|
||||
// TryLockRequest is a lock acquire request.
|
||||
type TryLockRequest struct {
|
||||
ResourceID string `json:"resourceId"`
|
||||
LockOwner string `json:"lockOwner"`
|
||||
ExpiryInSeconds int32 `json:"expiryInSeconds"`
|
||||
ResourceID string `json:"resourceId"`
|
||||
LockOwner string `json:"lockOwner"`
|
||||
ExpiryInSeconds int32 `json:"expiryInSeconds"`
|
||||
Metadata map[string]string `json:"metadata"`
|
||||
}
|
||||
|
||||
// UnlockRequest is a lock release request.
|
||||
type UnlockRequest struct {
|
||||
ResourceID string `json:"resourceId"`
|
||||
LockOwner string `json:"lockOwner"`
|
||||
ResourceID string `json:"resourceId"`
|
||||
LockOwner string `json:"lockOwner"`
|
||||
Metadata map[string]string `json:"metadata"`
|
||||
}
|
||||
|
|
|
@ -15,12 +15,14 @@ package lock
|
|||
|
||||
// Lock acquire request was successful or not.
|
||||
type TryLockResponse struct {
|
||||
Success bool `json:"success"`
|
||||
Success bool `json:"success"`
|
||||
Metadata map[string]string `json:"metadata"`
|
||||
}
|
||||
|
||||
// Status when releasing the lock.
|
||||
type UnlockResponse struct {
|
||||
Status Status `json:"status"`
|
||||
Status Status `json:"status"`
|
||||
Metadata map[string]string `json:"metadata"`
|
||||
}
|
||||
|
||||
type Status int32
|
||||
|
|
Loading…
Reference in New Issue