MCPcopy
hub / github.com/cortexlabs/cortex / buildHTTPTransport

Function buildHTTPTransport

pkg/proxy/proxy.go:40–48  ·  view source on GitHub ↗
(maxIdle, maxIdlePerHost int)

Source from the content-addressed store, hash-verified

38}
39
40func buildHTTPTransport(maxIdle, maxIdlePerHost int) http.RoundTripper {
41 transport := http.DefaultTransport.(*http.Transport).Clone()
42 transport.DisableKeepAlives = false
43 transport.MaxIdleConns = maxIdle
44 transport.MaxIdleConnsPerHost = maxIdlePerHost
45 transport.ForceAttemptHTTP2 = false
46 transport.DisableCompression = true
47 return transport
48}

Callers 1

NewReverseProxyFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected