disable keepalives so connections stop after data transfer complete

This commit is contained in:
Joe Lothan 2026-05-25 16:20:31 -04:00
parent ca90b7071e
commit 4c7a0f54f7

View file

@ -63,10 +63,9 @@ func processIcon(icon IconRow, cfg Config) DownloadResult {
// httpTransport is shared across all goroutines for connection pooling and TLS session reuse. // httpTransport is shared across all goroutines for connection pooling and TLS session reuse.
var httpTransport = &http.Transport{ var httpTransport = &http.Transport{
MaxIdleConns: 1000, MaxIdleConns: 0,
MaxIdleConnsPerHost: 2, MaxIdleConnsPerHost: 0,
IdleConnTimeout: 30 * time.Second, DisableKeepAlives: true,
DisableKeepAlives: false,
DialContext: (&net.Dialer{ DialContext: (&net.Dialer{
Timeout: 5 * time.Second, Timeout: 5 * time.Second,
KeepAlive: 30 * time.Second, KeepAlive: 30 * time.Second,