In net/http package, HTTP/2 is automatically enabled when TLS is enabled. But this may cause performance problems, we have also added the ability for users to selectively disable HTTP/2.
sample settings
settings.toml
# TLS and HTTP2 settings. TLS is required for HTTP2
enable_tls=true
enable_http2=true
# if you use HTTP2 or TLS, you need to prepare certificates and private keys
tls_cert_file="cert.pem"
tls_key_file="privkey.pem"
sumally
This changes allow TLS to be enabled.
In net/http package, HTTP/2 is automatically enabled when TLS is enabled. But this may cause performance problems, we have also added the ability for users to selectively disable HTTP/2.
sample settings
settings.toml
reference information