Struct holochain_websocket::WebsocketConfig[][src]

pub struct WebsocketConfig {
    pub scheme: &'static str,
    pub default_request_timeout_s: usize,
    pub tcp_keepalive_s: usize,
    pub max_send_queue: usize,
    pub max_message_size: usize,
    pub max_frame_size: usize,
    pub max_pending_connections: usize,
}
Expand description

A builder-style config struct for setting up websockets.

Fields

scheme: &'static str

Scheme to use for urls - e.g. “ws” or “wss”. [default = “ws”]

default_request_timeout_s: usize

Seconds after which the lib will stop tracking individual request ids. [default = 30]

tcp_keepalive_s: usize

We will treat the socket as disconnected if we receive no messages in this timeframe, using the tcp keepalive mechanism. [default = 10]

max_send_queue: usize

How many items are allowed in the outgoing queue. [default = 10]

max_message_size: usize

Maximum total message size of a websocket message. [default = 64M]

max_frame_size: usize

Maximum websocket frame size. [default = 16M]

max_pending_connections: usize

Maximum number of pending new incoming connections. [default = 255]

Implementations

Builder-style setter.

Builder-style setter.

Builder-style setter.

Builder-style setter.

Builder-style setter.

Builder-style setter.

Trait Implementations

Formats the value using the given formatter. Read more

Returns the “default value” for a type. Read more

Auto Trait Implementations

Blanket Implementations

Gets the TypeId of self. Read more

Immutably borrows from an owned value. Read more

Mutably borrows from an owned value. Read more

Performs the conversion.

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Instruments this type with the provided Span, returning an Instrumented wrapper. Read more

Instruments this type with the current Span, returning an Instrumented wrapper. Read more

Performs the conversion.

Should always be Self

The type returned in the event of a conversion error.

Performs the conversion.

The type returned in the event of a conversion error.

Performs the conversion.

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the provided Subscriber to this type, returning a WithDispatch wrapper. Read more

Attaches the current default Subscriber to this type, returning a WithDispatch wrapper. Read more