Commit daad34ab authored by Tatsuhiro Tsujikawa's avatar Tatsuhiro Tsujikawa

quic: Configure settings with options

parent 1bd57360
......@@ -271,9 +271,11 @@ int Http3Session::init_conn() {
nullptr, // push_stream,
};
auto config = client_->worker->config;
nghttp3_conn_settings settings;
nghttp3_conn_settings_default(&settings);
settings.qpack_max_table_capacity = 4096;
settings.qpack_max_table_capacity = config->header_table_size;
settings.qpack_blocked_streams = 100;
auto mem = nghttp3_mem_default();
......
......@@ -569,16 +569,17 @@ int Client::quic_init(const sockaddr *local_addr, socklen_t local_addrlen,
generate_cid(scid);
generate_cid(dcid);
auto config = worker->config;
ngtcp2_settings settings;
ngtcp2_settings_default(&settings);
settings.log_printf = debug_log_printf;
settings.log_printf = nullptr;
settings.initial_ts = timestamp(worker->loop);
settings.max_stream_data_bidi_local = 256_k;
settings.max_stream_data_bidi_remote = 256_k;
settings.max_stream_data_uni = 256_k;
settings.max_data = 1_m;
settings.max_streams_bidi = 1;
settings.max_stream_data_bidi_local = (1 << config->window_bits) - 1;
settings.max_stream_data_uni = (1 << config->window_bits) - 1;
settings.max_data = (1 << config->connection_window_bits) - 1;
settings.max_streams_bidi = 0;
settings.max_streams_uni = 100;
settings.idle_timeout = 30 * NGTCP2_SECONDS;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment