CloudSqlite.acquireWriteLock Function

Attempt to acquire the write lock for a container, with retries. If write lock is held by another user, call busyHandler if supplied. If no busyHandler, or handler returns "stop", throw. Otherwise try again.

acquireWriteLock(args: { busyHandler?: CloudSqlite.WriteLockBusyHandler, container: CloudSqlite.CloudContainer, user: string }): Promise<void>

@note if write lock is already held by the same user, this function will refresh the write lock's expiry time.

@throws if container is not connected to a CloudCache.

Parameter Type Description
args { busyHandler?: CloudSqlite.WriteLockBusyHandler, container: CloudSqlite.CloudContainer, user: string }  

Returns - Promise

Defined in

Last Updated: 17 December, 2024