#[non_exhaustive]pub struct Http2Options {Show 22 fields
pub adaptive_window: bool,
pub initial_stream_id: Option<u32>,
pub initial_conn_window_size: u32,
pub initial_window_size: u32,
pub initial_max_send_streams: usize,
pub max_frame_size: Option<u32>,
pub keep_alive_interval: Option<Duration>,
pub keep_alive_timeout: Duration,
pub keep_alive_while_idle: bool,
pub max_concurrent_reset_streams: Option<usize>,
pub max_send_buffer_size: usize,
pub max_concurrent_streams: Option<u32>,
pub max_header_list_size: Option<u32>,
pub max_pending_accept_reset_streams: Option<usize>,
pub enable_push: Option<bool>,
pub header_table_size: Option<u32>,
pub enable_connect_protocol: Option<bool>,
pub no_rfc7540_priorities: Option<bool>,
pub headers_pseudo_order: Option<PseudoOrder>,
pub headers_stream_dependency: Option<StreamDependency>,
pub settings_order: Option<SettingsOrder>,
pub priorities: Option<Priorities>,
}Expand description
Options for tuning HTTP/2 connections.
Http2Options lets you adjust how HTTP/2 works—stream limits, window sizes, frame and header
settings, and more. Most fields are optional and have sensible defaults. See each field for
details.
Fields (Non-exhaustive)§
This struct is marked as non-exhaustive
Struct { .. } syntax; cannot be matched against without a wildcard ..; and struct update syntax will not work.adaptive_window: boolWhether to use adaptive flow control.
initial_stream_id: Option<u32>The initial stream ID for the connection.
initial_conn_window_size: u32The initial window size for HTTP/2 connection-level flow control.
initial_window_size: u32The initial window size for HTTP/2 streams.
initial_max_send_streams: usizeThe initial maximum number of locally initiated (send) streams.
max_frame_size: Option<u32>The maximum frame size to use for HTTP/2.
keep_alive_interval: Option<Duration>The interval for HTTP/2 keep-alive ping frames.
keep_alive_timeout: DurationThe timeout for receiving an acknowledgement of the keep-alive ping.
keep_alive_while_idle: boolWhether HTTP/2 keep-alive should apply while the connection is idle.
max_concurrent_reset_streams: Option<usize>The maximum number of concurrent locally reset streams.
max_send_buffer_size: usizeThe maximum size of the send buffer for HTTP/2 streams.
max_concurrent_streams: Option<u32>The maximum number of concurrent streams initiated by the remote peer.
max_header_list_size: Option<u32>The maximum size of the header list.
max_pending_accept_reset_streams: Option<usize>The maximum number of pending accept reset streams.
enable_push: Option<bool>Whether to enable push promises.
header_table_size: Option<u32>The header table size for HPACK compression.
enable_connect_protocol: Option<bool>Whether to enable the CONNECT protocol.
no_rfc7540_priorities: Option<bool>Whether to disable RFC 7540 Stream Priorities.
headers_pseudo_order: Option<PseudoOrder>The HTTP/2 pseudo-header field order for outgoing HEADERS frames.
headers_stream_dependency: Option<StreamDependency>The stream dependency for the outgoing HEADERS frame.
settings_order: Option<SettingsOrder>The order of settings parameters in the initial SETTINGS frame.
priorities: Option<Priorities>The list of PRIORITY frames to be sent after connection establishment.
Implementations§
Source§impl Http2Options
impl Http2Options
Sourcepub fn builder() -> Http2OptionsBuilder
pub fn builder() -> Http2OptionsBuilder
Creates a new Http2OptionsBuilder instance.
Trait Implementations§
Source§impl Clone for Http2Options
impl Clone for Http2Options
Source§fn clone(&self) -> Http2Options
fn clone(&self) -> Http2Options
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read more