pub(crate) enum WebSocketProtocol {
SpdyTunnel,
Channels {
base64: bool,
},
}Expand description
A protocol a client may forward ports with over a WebSocket.
Variants§
SpdyTunnel
SPDY tunneled through binary messages.
Channels
The channel protocol, its payloads base64 encoded in text messages or as they are in binary ones.
Implementations§
Source§impl WebSocketProtocol
impl WebSocketProtocol
Sourcepub(crate) fn negotiate<'a>(
requested: impl IntoIterator<Item = &'a str>,
) -> Option<(Self, Option<&'static str>)>
pub(crate) fn negotiate<'a>( requested: impl IntoIterator<Item = &'a str>, ) -> Option<(Self, Option<&'static str>)>
The protocol for the subprotocols the client requested, with the one the server answers with. The tunnel wins like for the kubelet, otherwise the first supported one, none means binary channels.
Trait Implementations§
Source§impl Clone for WebSocketProtocol
impl Clone for WebSocketProtocol
impl Copy for WebSocketProtocol
Source§impl Debug for WebSocketProtocol
impl Debug for WebSocketProtocol
Source§impl PartialEq for WebSocketProtocol
impl PartialEq for WebSocketProtocol
impl StructuralPartialEq for WebSocketProtocol
Auto Trait Implementations§
impl Freeze for WebSocketProtocol
impl RefUnwindSafe for WebSocketProtocol
impl Send for WebSocketProtocol
impl Sync for WebSocketProtocol
impl Unpin for WebSocketProtocol
impl UnsafeUnpin for WebSocketProtocol
impl UnwindSafe for WebSocketProtocol
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
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§impl<T> FutureExt for T
impl<T> FutureExt for T
§fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
fn with_context(self, otel_cx: Context) -> WithContext<Self> ⓘ
§fn with_current_context(self) -> WithContext<Self> ⓘ
fn with_current_context(self) -> WithContext<Self> ⓘ
§impl<T> Instrument for T
impl<T> Instrument for T
§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
§impl<T> IntoRequest<T> for T
impl<T> IntoRequest<T> for T
§fn into_request(self) -> Request<T>
fn into_request(self) -> Request<T>
Wrap the input message
T in a tonic::Request§impl<L> LayerExt<L> for L
impl<L> LayerExt<L> for L
§fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
fn named_layer<S>(&self, service: S) -> Layered<<L as Layer<S>>::Service, S>where
L: Layer<S>,
Applies the layer to a service and wraps it in [
Layered].