Expand description
PDK Lock Library
Primitives for coordinating work among Flex Gateway workers and policies. Generated locks expire automatically if not refreshed and are released on drop.
§Primary types
LockBuilder/LockBuilderInstance: construct lock instances with custom expiration and optional isolation (LockBuilderInstance::sharedoption)TryLock: attempts to acquire a lock viaTryLock::try_lockLock: an acquired lock that can be refreshed viaLock::refresh_lock
Structs§
- Lock
- This is a try lock that expires automatically if it was not refreshed before the expiration time. The lock is released on drop.
- Lock
Builder - Represents the base builder for a
TryLockinstance. - Lock
Builder Instance - Represents a particular instance of a
LockBuilder. It includes extra metadata of the policy, required to successfully work in all scenarios involving multiple policies. - TryLock
- The built lock. Use this object’s
try_lockto ensure mutual exclusion.