DistributedLockProvider class abstract interface

Abstract contract for distributed locking across multi-instance production clusters.

Properties

hashCode → int
The hash code for this object.
no setterinherited
runtimeType → Type
A representation of the runtime type of the object.
no setterinherited

Methods

acquire(String resource, {Duration ttl = const Duration(seconds: 10)}) → Future<String?>
Attempts to acquire a distributed lock for resource with a lease ttl. Returns a fencing token or ownership string if successful, or null if locked.
noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
release(String resource, String lockToken) → Future<bool>
Releases the lock if lockToken matches current ownership.
toString() → String
A string representation of this object.
inherited

Operators

operator ==(Object other) → bool
The equality operator.
inherited