package nbd

  1. Overview
  2. Docs

Parameters

module R : RPC

Signature

exception Unexpected_id of R.id
exception Shutdown
type client = {
  1. transport : R.transport;
  2. outgoing_mutex : Lwt_mutex.t;
  3. id_to_wakeup : (R.id, R.request_hdr * [ `Ok of unit | `Error of Protocol.Error.t ] Lwt.u * R.response_body) Hashtbl.t;
  4. mutable dispatcher_thread : unit Lwt.t;
  5. mutable dispatcher_shutting_down : bool;
}
val dispatcher : client -> 'a Lwt.t
val rpc : R.request_hdr -> R.request_body -> R.response_body -> client -> [ `Error of Protocol.Error.t | `Ok of unit ] Lwt.t
val create : R.transport -> client Lwt.t