You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
-`acquireAttemptsLimit` - _optional_ max number of attempts to be made in `.acquire()` call
39
39
-`retryInterval` - _optional_ ms, time between acquire attempts if resource locked
40
40
-`refreshInterval` - _optional_ ms, auto-refresh interval; to disable auto-refresh behaviour set `0`
41
+
-`externallyAcquiredIdentifier` - _optional_ uuid, previously acquired mutex identifier (useful for lock sharing between processes: acquire in scheduler, refresh and release in handler)
41
42
-`onLockLost` - _optional_ function, called when lock loss is detected due refresh cycle; default onLockLost throws unhandled LostLockError
42
43
43
44
#### Example
@@ -120,14 +121,59 @@ async function doSomething() {
120
121
return
121
122
}
122
123
try {
123
-
// critical cycle iteration
124
+
// critical cycle iteration
124
125
} finally {
125
-
// We want to let lock expire over time after operation is finished
126
+
// We want to let lock expire over time after operation is finished
0 commit comments