fix retry when writer is reset on push
A dynamic pipe is created in the body of the request, so that everytime a GetBody() call is made, a new pipe gets generated to which the content can be written, and the http body can be read from the PipeReader, thus solving the body reuse issue.
Fixes: #5978
Hi @akhilerm. Thanks for your PR.
I'm waiting for a containerd member to verify that this patch is reasonable to test. If it is, they should reply with /ok-to-test on its own line. Until that is done, I will not automatically test new commits in this PR, but the usual testing commands by org members will still work. Regular contributors should join the org to skip this step.
Once the patch is verified, the new status will be reflected by the ok-to-test label.
I understand the commands that are listed here.
Instructions for interacting with me using PR comments are available here. If you have questions or suggestions related to my behavior, please file an issue against the kubernetes/test-infra repository.
cc: @dmcgowan updated the changes in the PR as discussed. Also added a reference to a commit that is used for testing with docker config.
@dmcgowan @tonistiigi Can you take a look at this PR?
/ok-to-test
@mikebrow Can you review this PR once more?
Should this change be cherry-picked to 1.6 / 1.5 ?
Should this change be cherry-picked to 1.6 / 1.5 ?
Yes, I think so. This is a long-standing bug that has affected quite a few users so should be cherry-picked to our supported releases.