Skip to main content

Module client

Module client 

Source

Re-exports§

pub use builder::ClientBuilder;

Modules§

builder
http 🔒
HTTP client backend: HTTP/1.1 (smol, or pooled on tokio), opt-in HTTP/2 over plain TCP, and HTTP/3 (QUIC).
message_dispatcher 🔒
multiplexed 🔒
Multiplexed client mode (TCP/TLS/Unix and WS/WSS). A single message connection is shared across all calls and subscriptions. A background task splits reader from writer.
quic_stream 🔒
QUIC client mode: one stream per call, one stream per subscription.
subscriptions 🔒

Structs§

Client
An RPC client that connects to a JSON-RPC 2.0 server.
ClientConfig 🔒
HttpConfig
HTTP settings for http:// endpoints, set with ClientBuilder::http_config.
Subscription
A subscription established when the client’s subscribe to a method

Enums§

ClientBackend 🔒

Traits§

WsCodec
Bound on the WebSocket codec generic. With the ws feature it requires JsonRpcWsCodec; otherwise it accepts any clonable type (the codec is unused) so callers can pass JsonCodec unchanged.

Type Aliases§

NotificationDecoder
Turns a received notification into its subscription id and result. Must match the server’s notification encoder.
RequestID 🔒