pub struct WebsocketConfig {
pub default_request_timeout: Duration,
pub max_message_size: usize,
pub max_frame_size: usize,
pub allowed_origins: Option<AllowedOrigins>,
}Expand description
Websocket configuration struct.
Fields§
§default_request_timeout: DurationSeconds after which the lib will stop tracking individual request ids. [default = 60 seconds]
max_message_size: usizeMaximum total message size of a websocket message. [default = 64M]
max_frame_size: usizeMaximum websocket frame size. [default = 16M]
allowed_origins: Option<AllowedOrigins>Allowed origins access control for a WebsocketListener. Not used by the WebsocketSender.
Implementations§
Source§impl WebsocketConfig
impl WebsocketConfig
Sourcepub const CLIENT_DEFAULT: WebsocketConfig
pub const CLIENT_DEFAULT: WebsocketConfig
The default client WebsocketConfig.
Sourcepub const LISTENER_DEFAULT: WebsocketConfig
pub const LISTENER_DEFAULT: WebsocketConfig
The default listener WebsocketConfig.
Trait Implementations§
Source§impl Clone for WebsocketConfig
impl Clone for WebsocketConfig
Source§fn clone(&self) -> WebsocketConfig
fn clone(&self) -> WebsocketConfig
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for WebsocketConfig
impl RefUnwindSafe for WebsocketConfig
impl Send for WebsocketConfig
impl Sync for WebsocketConfig
impl Unpin for WebsocketConfig
impl UnwindSafe for WebsocketConfig
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> FutureExt for T
impl<T> FutureExt for T
Source§fn with_context(self, otel_cx: Context) -> WithContext<Self>
fn with_context(self, otel_cx: Context) -> WithContext<Self>
Source§fn with_current_context(self) -> WithContext<Self>
fn with_current_context(self) -> WithContext<Self>
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self>
fn instrument(self, span: Span) -> Instrumented<Self>
Source§fn in_current_span(self) -> Instrumented<Self>
fn in_current_span(self) -> Instrumented<Self>
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self>
fn into_either(self, into_left: bool) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more