Versions in this module Expand all Collapse all v3 v3.0.1 Feb 23, 2021 Changes in this version + type GetSyncLimit func(string) (int, error) + type IsWorkflowDeleted func(string) bool + type LockKind string + const LockKindConfigMap + const LockKindMutex + type LockName struct + Key string + Kind LockKind + Namespace string + ResourceName string + func DecodeLockName(lockName string) (*LockName, error) + func GetLockName(sync *v1alpha1.Synchronization, namespace string) (*LockName, error) + func NewLockName(namespace, resourceName, lockKey string, kind LockKind) *LockName + func (ln *LockName) EncodeName() string + func (ln *LockName) Validate() error + func (ln *LockName) ValidateEncoding(encoding string) string + type Manager struct + func NewLockManager(getSyncLimit GetSyncLimit, nextWorkflow NextWorkflow, ...) *Manager + func (cm *Manager) CheckWorkflowExistence() + func (cm *Manager) Initialize(wfs []wfv1.Workflow) + func (cm *Manager) Release(wf *wfv1.Workflow, nodeName string, syncRef *wfv1.Synchronization) + func (cm *Manager) ReleaseAll(wf *wfv1.Workflow) bool + func (cm *Manager) TryAcquire(wf *wfv1.Workflow, nodeName string, syncLockRef *wfv1.Synchronization) (bool, bool, string, error) + type NextWorkflow func(string) + type PriorityMutex struct + func NewMutex(name string, nextWorkflow NextWorkflow) *PriorityMutex + type PrioritySemaphore struct + func NewSemaphore(name string, limit int, nextWorkflow NextWorkflow, lockType string) *PrioritySemaphore + type Semaphore interface + type Throttler interface + Add func(key string, priority int32, creationTime time.Time) + Admit func(key string) bool + Remove func(key string) + func NewThrottler(parallelism int, queue func(key string)) Throttler