open-net 0.3.5

A cross-platform async networking library for Rust with HTTP and WebSocket clients, network status monitoring, configurable retries, WebSocket reconnection and heartbeats, and managed client lifecycles. Reuse common networking infrastructure across applications to avoid repeated implementation and debugging, helping save development time and AI coding tokens.
Documentation
1
2
3
4
5
6
7
8
9
10
11
use tokio::sync::oneshot;

/// Work submitted to the client's original bounded callback dispatcher.
pub(crate) enum CallbackEvent {
    SessionJob {
        session_id: crate::ws::SessionId,
        job: crate::module::ws_client::listener_executor::CallbackJob,
    },
    /// Finish queued callbacks when the entire client shuts down.
    DataDrain { delivered: oneshot::Sender<()> },
}