-
Notifications
You must be signed in to change notification settings - Fork 53
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
transport/http: fix metrics race condition
This PR fixes a race condition reported by #548, by introducing a simple wrapper for time.Time. While by default aws-sdk-go-v2 uses NopMeterProvider, the transport/http internals are still instrumenting the http requests (the withMetrics func). Maybe there is a room for improvement, to not call httptrace.WithClientTrace when the meter is nop, however this is out of scope for this PR.
- Loading branch information
Showing
1 changed file
with
29 additions
and
15 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters