Skip to main content

join_or_abort

Function join_or_abort 

Source
async fn join_or_abort<T>(
    writer: JoinHandle<T>,
    written: &Activity,
) -> Option<T>
Expand description

Wait for the task which writes to a WebSocket and closes it, abort it once the client did not take anything for STALL_TIMEOUT, see ClientIo::written. A slow client still gets what is queued. Dropping its handle would leave it running, a writer to a client which does not read would hold the connection. The output of the writer, None if it did not end.