Module Lock_file_async.Flock
type tNfshas analogues of functions inLock_file.Flock; see there for documentation. In addition to addingDeferreds, this module adds functions that operate in theDeferred.Or_error.tmonad.
val lock_exn : lock_path:string -> [ `Somebody_else_took_it | `We_took_it of t ] Async.Deferred.tval lock : lock_path:string -> [ `Somebody_else_took_it | `We_took_it of t ] Async.Deferred.Or_error.tval unlock_exn : t -> unit Async.Deferred.tval unlock : t -> unit Async.Deferred.Or_error.tval wait_for_lock_exn : ?abort:unit Async.Deferred.t -> lock_path:string -> unit -> t Async.Deferred.twait_for_lock_exn ?abort ~lock_path ()Wait for the lock, giving up onceabortbecomes determined
val wait_for_lock : ?abort:unit Async.Deferred.t -> lock_path:string -> unit -> t Async.Deferred.Or_error.tSee
wait_for_lock_exn