Module Qcow_locks.Write
- val with_lock : ?client:Client.t -> t -> Qcow_types.Cluster.t -> (unit -> 'a Lwt.t) -> 'a Lwt.t
- with_lock t fexecutes- f ()with the lock held for writing
- val with_locks : ?client:Client.t -> t -> first:Qcow_types.Cluster.t -> last:Qcow_types.Cluster.t -> (unit -> 'a Lwt.t) -> 'a Lwt.t
- with_locks t ~first ~last fexecutes- f ()with all clusters in the interval- first .. lastinclusive locked for writing.
- val try_lock : ?client:Client.t -> t -> Qcow_types.Cluster.t -> lock option
- try_lock ?client t clusterreturns a write lock on- clusterif it can be done without blocking, or returns None.