@@ -57,6 +57,7 @@ pub(crate) struct Config {
57
57
pub ( crate ) adaptive_window : bool ,
58
58
pub ( crate ) initial_conn_window_size : u32 ,
59
59
pub ( crate ) initial_stream_window_size : u32 ,
60
+ pub ( crate ) initial_max_send_streams : Option < usize > ,
60
61
pub ( crate ) max_frame_size : u32 ,
61
62
pub ( crate ) keep_alive_interval : Option < Duration > ,
62
63
pub ( crate ) keep_alive_timeout : Duration ,
@@ -71,6 +72,7 @@ impl Default for Config {
71
72
adaptive_window : false ,
72
73
initial_conn_window_size : DEFAULT_CONN_WINDOW ,
73
74
initial_stream_window_size : DEFAULT_STREAM_WINDOW ,
75
+ initial_max_send_streams : None ,
74
76
max_frame_size : DEFAULT_MAX_FRAME_SIZE ,
75
77
keep_alive_interval : None ,
76
78
keep_alive_timeout : Duration :: from_secs ( 20 ) ,
@@ -89,6 +91,9 @@ fn new_builder(config: &Config) -> Builder {
89
91
. max_frame_size ( config. max_frame_size )
90
92
. max_send_buffer_size ( config. max_send_buffer_size )
91
93
. enable_push ( false ) ;
94
+ if let Some ( initial_max_send_streams) = config. initial_max_send_streams {
95
+ builder. initial_max_send_streams ( initial_max_send_streams) ;
96
+ }
92
97
if let Some ( max) = config. max_concurrent_reset_streams {
93
98
builder. max_concurrent_reset_streams ( max) ;
94
99
}
0 commit comments