Allow Content-Length to be omitted when pushing on patch requests#404
Open
z4ce wants to merge 2 commits intoopencontainers:mainfrom
Open
Allow Content-Length to be omitted when pushing on patch requests#404z4ce wants to merge 2 commits intoopencontainers:mainfrom
z4ce wants to merge 2 commits intoopencontainers:mainfrom
Conversation
Author
|
I think there should be further discussion if the POST+PUT method should also be modified to allow chunked encoding, but I wanted introduce this independently as it updates the specification to reflect the current real-world usage by the docker cli. |
Technically due to the way the specification is written today the moby/docker cli push is nonconformant. Given that is one of the most common ways users are pushing today, the specification should recognize that it is allowed. Further, requiring `Content-Length` to be set means that no client that is conforming can use http chunked encoding, which limits the use of CDNs like CloudFlare and other reverse proxies. See further discussion at: containerd/containerd#7459 Signed-off-by: Ian Zink <ian@replicated.com>
sudo-bmitch
requested changes
May 27, 2023
Contributor
sudo-bmitch
left a comment
There was a problem hiding this comment.
What happens to the Content-Range when the length is unknown?
jdolitsky
reviewed
Jun 21, 2023
Signed-off-by: Josh Dolitsky <393494+jdolitsky@users.noreply.github.com>
jdolitsky
approved these changes
Jun 21, 2023
jdolitsky
requested changes
Jun 21, 2023
Contributor
jdolitsky
left a comment
There was a problem hiding this comment.
dropping from 1.1 milestone
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.
Technically due to the way the specification is written today the moby/docker cli push is nonconformant. Given that is one of the most common ways users are pushing today, the specification should recognize that it is allowed.
Further, requiring
Content-Lengthto be set means that no client that is conforming can use http chunked encoding, which limits the use of CDNs like CloudFlare and other reverse proxies. See further discussion at: containerd/containerd#7459