This module allows the jenga server to incrementally send updates about build errors in a typed way to clients (see the errors rpc).
type t
A Reportable.t
is an updatable bag of reportable errors, with clients.
When a client attaches it receives a snapshot and a pipe of updates.
include sig ... end
val sexp_of_t : t ‑> Sexplib.Sexp.t
val create : name:string ‑> t
create t
returns a new Reportable.t
to which errors can be add
ed and remove
d
name
is shown by "jenga -trace" when clients register/unregister
module Snap : sig ... end
module Update : sig ... end
module Stable : sig ... end
val drop_clients : t ‑> unit
Drop all clients attached to the Reportable.t
. Useful for testing the reconnection
logic of clients.
val snap_with_updates : trace:(string ‑> unit) ‑> t ‑> Snap.t * Update.t Async.Pipe.Reader.t
snap_with_updates ~trace t
attaches a new client, returning the snapshot & update
pipe. The client is detached when the caller closes the returned pipe-reader.
The intended use of snap_with_updates
is the Error_pipe
RPC; constructing a
`mirror' Reportable.t
on the client-side of the RPC using of_snap
and update
.