[GODRIVER-2623] Use a clone of the http.DefaultTransport for the internal HTTP client. Created: 27/Oct/22  Updated: 28/Oct/23  Resolved: 08/Nov/22

Status: Closed
Project: Go Driver
Component/s: None
Affects Version/s: None
Fix Version/s: 1.12.0, 1.12.0-alpha1

Type: Improvement Priority: Unknown
Reporter: Matt Dale Assignee: Matt Dale
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
depends on GODRIVER-2174 Bump the minimum Go version to 1.13 Closed
depends on GODRIVER-2050 Be able to supply http.Transport for ... Closed
Related
is related to GODRIVER-2603 Use errors API from Go 1.13 Closed

 Description   

For the internal.DefaultHTTPClient, instead of creating a new http.Transport that may deviate from the Go http.DefaultTransport over time, use http.DefaultTransport.Clone().

Note that the Clone function is available starting in Go 1.13, so it depends on GODRIVER-2174 and should only be added after the Go Driver 1.11 release (1.11 documents the min Go version change, but should not include any actual build-breaking changes).

See this Go issue for more details about why Clone() was added and how to use it.



 Comments   
Comment by Githook User [ 08/Nov/22 ]

Author:

{'name': 'Eric Daniels', 'email': 'eric@erdaniels.com', 'username': 'edaniels'}

Message: GODRIVER-2623 - Use http.Transport.Clone from golang 1.13 (#1115)
Branch: master
https://github.com/mongodb/mongo-go-driver/commit/c4073ad4b6cae1809a18f857beb92da010c06638

Generated at Thu Feb 08 08:39:02 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.