livery_client_timeout (livery v0.6.0)
View SourceClient layer: bound a request to a deadline.
Runs the downstream call in a monitored child process and returns
{error, timeout} if it does not finish within Ms, killing the child
(which tears down the in-flight connection). Add it with
livery_client:timeout/1.
A {stream, Reader} response body holds a live connection owned by the
child. Before the child exits, this layer hands that connection to the
caller via the adapter's adopt/2, so the caller's later read/1 does not
race the child's death.
Summary
Functions
-spec call(livery_client:request(), livery_client:next(), pos_integer()) -> {ok, livery_client:response()} | {error, term()}.