Documentation
¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type KeyMutex ¶
type KeyMutex interface {
// Aquires a lock associated with the specified ID, creates the lock if one doesn't already exist.
LockKey(id string)
// Releases the lock associated with the specified ID.
// Returns an error if the specified ID doesn't exist.
UnlockKey(id string) error
}
KeyMutex is a thread-safe interface for aquiring locks on arbitrary strings.
Click to show internal directories.
Click to hide internal directories.