diff options
| author | Paweł Stołowski <stolowski@gmail.com> | 2021-07-12 16:38:38 +0200 |
|---|---|---|
| committer | Paweł Stołowski <stolowski@gmail.com> | 2021-07-13 09:41:58 +0200 |
| commit | 0f17e9aebbe3baefcbe45c81c8d95bb58e9f3b6a (patch) | |
| tree | 01373535f4d225730cdb13384b29c6052e0f0c25 | |
| parent | e37c023a8cb45b4b61cbe4f2c1b3eb293eda29d6 (diff) | |
Bump ResponseHeaderTimeout to 15s.
| -rw-r--r-- | httputil/transport.go | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/httputil/transport.go b/httputil/transport.go index b172ce9991..24102ef14e 100644 --- a/httputil/transport.go +++ b/httputil/transport.go @@ -25,10 +25,11 @@ import ( ) var origDefaultTransport *http.Transport = http.DefaultTransport.(*http.Transport) -var responseHeaderTimeout = 10 * time.Second +var responseHeaderTimeout = 15 * time.Second // newDefaultTransport makes a fresh modifiable instance of Transport -// with the same parameters as http.DefaultTransport. +// with the same parameters as http.DefaultTransport but we also set +// ResponseHeaderTimeout which is not set by default. func newDefaultTransport() *http.Transport { // based on https://github.com/golang/go/blob/release-branch.go1.7/src/net/http/transport.go#L38 return &http.Transport{ |
