[release/1.4 backport] Fix missing Body.Close() calls on push to docker remote#5717
Merged
estesp merged 1 commit intocontainerd:release/1.4from Jul 12, 2021
Conversation
|
Build succeeded.
|
Member
Author
|
Ah, hmmm.. perhaps not needed in 1.4.x, or in a slightly different fashion; |
> note: This is a slightly modified version of the commit in main, because > pusher.Commit() uses a regular http.Response, not a wrapped one. Discovered this while using HTTP tracing via OpenTelemetry inside of buildkitd, where the trace spans were not being reported for the registry PUT http requests. The spans are only reported on the Close for the Body, after adding these Close calls, the spans are reported as expected. Signed-off-by: coryb <cbennett@netflix.com> (cherry picked from commit 894b6ae) Signed-off-by: Sebastiaan van Stijn <github@gone.nl>
f219b40 to
591744a
Compare
|
Build succeeded.
|
thaJeztah
commented
Jul 12, 2021
Member
Author
|
could use some extra eyes on this one to verify this is all correct for the 1.4 implementation (as some things changed; see above), and this code is not trivial |
dmcgowan
approved these changes
Jul 12, 2021
This file contains hidden or 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
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
backport of #5712
Discovered this while using HTTP tracing via OpenTelemetry inside of
buildkitd, where the trace spans were not being reported for the
registry PUT http requests. The spans are only reported on the Close
for the Body, after adding these Close calls, the spans are reported as
expected.
Signed-off-by: coryb cbennett@netflix.com
(cherry picked from commit 894b6ae)
Signed-off-by: Sebastiaan van Stijn github@gone.nl