Skip to content

Commit

Permalink
Add ForceAttemptHTTP2 true to default transport
Browse files Browse the repository at this point in the history
  • Loading branch information
jefferai committed Feb 3, 2021
1 parent d3fcbee commit 6d9e2ac
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 0 deletions.
1 change: 1 addition & 0 deletions cleanhttp.go
Original file line number Diff line number Diff line change
Expand Up @@ -32,6 +32,7 @@ func DefaultPooledTransport() *http.Transport {
IdleConnTimeout: 90 * time.Second,
TLSHandshakeTimeout: 10 * time.Second,
ExpectContinueTimeout: 1 * time.Second,
ForceAttemptHTTP2: true,
MaxIdleConnsPerHost: runtime.GOMAXPROCS(0) + 1,
}
return transport
Expand Down
2 changes: 2 additions & 0 deletions go.mod
Original file line number Diff line number Diff line change
@@ -1 +1,3 @@
module github.com/hashicorp/go-cleanhttp

go 1.13

0 comments on commit 6d9e2ac

Please sign in to comment.