Module Rpc.Connection

include module type of sig ... end
type t = Async_rpc_kernel__Rpc.Connection.t
val sexp_of_t : t -> Ppx_sexp_conv_lib.Sexp.t
val create : ?⁠implementations:'s Async_rpc_kernel__.Implementations.t -> connection_state:(t -> 's) -> ?⁠handshake_timeout:Core_kernel.Time_ns.Span.t -> ?⁠heartbeat_config:Heartbeat_config.t -> ?⁠description:Core_kernel.Info.t -> ?⁠time_source:Async_kernel.Synchronous_time_source.t -> Async_rpc_kernel__.Transport.t -> (tCore_kernel.Exn.t) Core_kernel.Result.t Async_kernel.Deferred.t
val contains_magic_prefix : bool Bin_prot.Type_class.reader
val description : t -> Core_kernel.Info.t
val add_heartbeat_callback : t -> (unit -> unit) -> unit
val close : ?⁠streaming_responses_flush_timeout:Core_kernel.Time_ns.Span.t -> ?⁠reason:Core_kernel.Info.t -> t -> unit Async_kernel.Deferred.t
val close_finished : t -> unit Async_kernel.Deferred.t
val close_reason : t -> on_close:[ `finished | `started ] -> Core_kernel.Info.t Async_kernel.Deferred.t
val is_closed : t -> bool
val bytes_to_write : t -> int
val flushed : t -> unit Async_kernel.Deferred.t
val with_close : ?⁠implementations:'s Async_rpc_kernel__.Implementations.t -> ?⁠handshake_timeout:Core_kernel.Time_ns.Span.t -> ?⁠heartbeat_config:Heartbeat_config.t -> connection_state:(t -> 's) -> Async_rpc_kernel__.Transport.t -> dispatch_queries:(t -> 'a Async_kernel.Deferred.t) -> on_handshake_error:[ `Call of Core_kernel.Exn.t -> 'a Async_kernel.Deferred.t | `Raise ] -> 'a Async_kernel.Deferred.t
val server_with_close : ?⁠handshake_timeout:Core_kernel.Time_ns.Span.t -> ?⁠heartbeat_config:Heartbeat_config.t -> Async_rpc_kernel__.Transport.t -> implementations:'s Async_rpc_kernel__.Implementations.t -> connection_state:(t -> 's) -> on_handshake_error:[ `Call of Core_kernel.Exn.t -> unit Async_kernel.Deferred.t | `Ignore | `Raise ] -> unit Async_kernel.Deferred.t
type ('rest, 'implementations) client_t = ?⁠uri:Async_js__.Ocaml_uri.Uri.t -> ?⁠heartbeat_config:Heartbeat_config.t -> ?⁠description:Core_kernel.Info.t -> ?⁠implementations:'implementations Client_implementations.t -> 'rest

This type of client connects to the websocket at the root of some host and port, i.e. ws://<address>/.

val client : (unit -> t Async_kernel.Deferred.Or_error.t's) client_t
val client_exn : (unit -> t Async_kernel.Deferred.t's) client_t