Documentation
¶
Overview ¶
Package syncx contains small synchronization primitives shared by Axiom frontends.
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type KeyedLocker ¶
type KeyedLocker struct {
// contains filtered or unexported fields
}
KeyedLocker serializes work for one key while allowing independent keys to run concurrently. Lock returns an idempotent-by-contract unlock function that must be called exactly once.
func NewKeyedLocker ¶
func NewKeyedLocker() *KeyedLocker
func (*KeyedLocker) Lock ¶
func (k *KeyedLocker) Lock(key string) func()
Click to show internal directories.
Click to hide internal directories.