AcquireLockProperties interface
Describes the properties that must be provided while acquiring a lock.
Properties
abort |
An implementation of the |
timeout |
The allowed amount of time in milliseconds to acquire a lock.
If a lock isn't acquired within this time, the promise returned
by |
Property Details
abortSignal
An implementation of the AbortSignalLike
interface to signal the request to cancel lock acquisition.
This only applies to the acquisition of a lock. Once the lock is acquired, the task is invoked and acquire
can no longer be cancelled.
This does not cancel running the task passed to acquire()
if the lock has been acquired,
but will prevent it from running if cancelled before the task is invoked.
abortSignal: undefined | AbortSignalLike
Property Value
undefined | AbortSignalLike
timeoutInMs
The allowed amount of time in milliseconds to acquire a lock.
If a lock isn't acquired within this time, the promise returned
by acquire()
will be rejected with an Error.
timeoutInMs: undefined | number
Property Value
undefined | number