add configuration for http2_max_concurrent_streams
This commit is contained in:
parent
43fa61cabd
commit
d9cfad1894
3 changed files with 14 additions and 0 deletions
|
@ -51,6 +51,7 @@ The following table shows a configuration option's name, type, and the default v
|
||||||
|[http2-max-field-size](#http2-max-field-size)|string|"4k"|
|
|[http2-max-field-size](#http2-max-field-size)|string|"4k"|
|
||||||
|[http2-max-header-size](#http2-max-header-size)|string|"16k"|
|
|[http2-max-header-size](#http2-max-header-size)|string|"16k"|
|
||||||
|[http2-max-requests](#http2-max-requests)|int|1000|
|
|[http2-max-requests](#http2-max-requests)|int|1000|
|
||||||
|
|[http2-max-concurrent-streams](#http2-max-concurrent-streams)|int|1000|
|
||||||
|[hsts](#hsts)|bool|"true"|
|
|[hsts](#hsts)|bool|"true"|
|
||||||
|[hsts-include-subdomains](#hsts-include-subdomains)|bool|"true"|
|
|[hsts-include-subdomains](#hsts-include-subdomains)|bool|"true"|
|
||||||
|[hsts-max-age](#hsts-max-age)|string|"15724800"|
|
|[hsts-max-age](#hsts-max-age)|string|"15724800"|
|
||||||
|
@ -310,6 +311,13 @@ Sets the maximum number of requests (including push requests) that can be served
|
||||||
_References:_
|
_References:_
|
||||||
[http://nginx.org/en/docs/http/ngx_http_v2_module.html#http2_max_requests](http://nginx.org/en/docs/http/ngx_http_v2_module.html#http2_max_requests)
|
[http://nginx.org/en/docs/http/ngx_http_v2_module.html#http2_max_requests](http://nginx.org/en/docs/http/ngx_http_v2_module.html#http2_max_requests)
|
||||||
|
|
||||||
|
## http2-max-concurrent-streams
|
||||||
|
|
||||||
|
Sets the maximum number of concurrent HTTP/2 streams in a connection.
|
||||||
|
|
||||||
|
_References:_
|
||||||
|
[http://nginx.org/en/docs/http/ngx_http_v2_module.html#http2_max_concurrent_streams](http://nginx.org/en/docs/http/ngx_http_v2_module.html#http2_max_concurrent_streams)
|
||||||
|
|
||||||
## hsts
|
## hsts
|
||||||
|
|
||||||
Enables or disables the header HSTS in servers running SSL.
|
Enables or disables the header HSTS in servers running SSL.
|
||||||
|
|
|
@ -196,6 +196,10 @@ type Configuration struct {
|
||||||
// and the need of establishing a new connection.
|
// and the need of establishing a new connection.
|
||||||
HTTP2MaxRequests int `json:"http2-max-requests,omitempty"`
|
HTTP2MaxRequests int `json:"http2-max-requests,omitempty"`
|
||||||
|
|
||||||
|
// http://nginx.org/en/docs/http/ngx_http_v2_module.html#http2_max_concurrent_streams
|
||||||
|
// Sets the maximum number of concurrent HTTP/2 streams in a connection.
|
||||||
|
HTTP2MaxConcurrentStreams int `json:"http2-max-concurrent-streams,omitempty"`
|
||||||
|
|
||||||
// Enables or disables the header HSTS in servers running SSL
|
// Enables or disables the header HSTS in servers running SSL
|
||||||
HSTS bool `json:"hsts,omitempty"`
|
HSTS bool `json:"hsts,omitempty"`
|
||||||
|
|
||||||
|
@ -676,6 +680,7 @@ func NewDefault() Configuration {
|
||||||
HTTP2MaxFieldSize: "4k",
|
HTTP2MaxFieldSize: "4k",
|
||||||
HTTP2MaxHeaderSize: "16k",
|
HTTP2MaxHeaderSize: "16k",
|
||||||
HTTP2MaxRequests: 1000,
|
HTTP2MaxRequests: 1000,
|
||||||
|
HTTP2MaxConcurrentStreams: 128,
|
||||||
HTTPRedirectCode: 308,
|
HTTPRedirectCode: 308,
|
||||||
HSTS: true,
|
HSTS: true,
|
||||||
HSTSIncludeSubdomains: true,
|
HSTSIncludeSubdomains: true,
|
||||||
|
|
|
@ -210,6 +210,7 @@ http {
|
||||||
http2_max_field_size {{ $cfg.HTTP2MaxFieldSize }};
|
http2_max_field_size {{ $cfg.HTTP2MaxFieldSize }};
|
||||||
http2_max_header_size {{ $cfg.HTTP2MaxHeaderSize }};
|
http2_max_header_size {{ $cfg.HTTP2MaxHeaderSize }};
|
||||||
http2_max_requests {{ $cfg.HTTP2MaxRequests }};
|
http2_max_requests {{ $cfg.HTTP2MaxRequests }};
|
||||||
|
http2_max_concurrent_streams {{ $cfg.HTTP2MaxConcurrentStreams }};
|
||||||
|
|
||||||
types_hash_max_size 2048;
|
types_hash_max_size 2048;
|
||||||
server_names_hash_max_size {{ $cfg.ServerNameHashMaxSize }};
|
server_names_hash_max_size {{ $cfg.ServerNameHashMaxSize }};
|
||||||
|
|
Loading…
Reference in a new issue