Set DNS http maximu idle connection to 3 minutes

This commit is contained in:
Vladimir Stoilov 2022-07-21 15:37:52 +02:00
parent 652e27d3ce
commit 59e2c56e0f

View file

@ -8,6 +8,7 @@ import (
"io/ioutil"
"net/http"
"net/url"
"time"
"github.com/miekg/dns"
)
@ -45,6 +46,7 @@ func NewHTTPSResolver(resolver *Resolver) *HTTPSResolver {
ServerName: resolver.Info.Domain,
// TODO: use portbase rng
},
IdleConnTimeout: 3 * time.Minute,
}
client := &http.Client{Transport: tr}