Function default_tls_alpn
pub fn default_tls_alpn(protocol: &Protocol) -> Option<TlsAlpn>Available on crate feature
tls only.Expand description
Return Rama’s default ALPN offer for an application protocol.
HTTP can negotiate HTTP/2 or HTTP/1.1. WebSocket defaults to HTTP/1.1 because
HTTP/2 WebSocket support cannot be known until after ALPN negotiation; an
explicit target HTTP version can opt into HTTP/2. Protocols without a
standardized ALPN in Rama, including ICAPS and custom protocols, return
None.