Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

add application/vnd.oci.image.layer.v1.tar+zstd to official media type? #787

Closed
AkihiroSuda opened this issue Aug 2, 2019 · 6 comments · Fixed by #788
Closed

add application/vnd.oci.image.layer.v1.tar+zstd to official media type? #787

AkihiroSuda opened this issue Aug 2, 2019 · 6 comments · Fixed by #788

Comments

@AkihiroSuda
Copy link
Member

containers/image#639 (comment)

@vbatts @giuseppe

@vrothberg
Copy link
Contributor

👍 from my side

FYI @mtrmac @mrunalp @rhatdan

@rhatdan
Copy link

rhatdan commented Aug 4, 2019

👍

@cyphar
Copy link
Member

cyphar commented Aug 5, 2019

Sounds like a good idea to me, the main question is whether we should require support or define it as a SHOULD (such that we define +zstd to mean something specific without requiring everyone implement support).

Though, given there is a C library (used fairly widely now) and implementations for Go and Rust, I'd be willing to argue that implementing support shouldn't be an onerous requirement for image consumers.

Does anyone want to volunteer to do the PR, or should I?

@vbatts
Copy link
Member

vbatts commented Aug 12, 2019 via email

giuseppe added a commit to giuseppe/image-spec that referenced this issue Aug 21, 2019
Closes: opencontainers#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
@giuseppe
Copy link
Member

I've opened a PR here: #788

giuseppe added a commit to giuseppe/image-spec that referenced this issue Aug 21, 2019
Closes: opencontainers#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
giuseppe added a commit to giuseppe/image-spec that referenced this issue Aug 21, 2019
Closes: opencontainers#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
@jonjohnsonjr
Copy link
Contributor

@vbatts do we care if OCI media types are valid RFC6838 media types? E.g. "zstd" isn't defined in the Structured Syntax Suffix Registry.

Media types that make use of a named structured syntax SHOULD use the appropriate registered "+suffix" for that structured syntax when they are registered. By the same token, media types MUST NOT be given names incorporating suffixes for structured syntaxes they do not actually employ. "+suffix" constructs for as-yet unregistered structured syntaxes SHOULD NOT be used, given the possibility of conflicts with future suffix definitions.

This ties into #747 as well. I'm not sure if the +enc double-suffix is valid (though I mostly skimmed that RFC and might misunderstand the grammar described).

I was thinking about how I'd go about adding support for zstd in various places, and I'm a bit worried that, as we add more dimensions to the media types, we're going to end up with a combinatoric explosion of valid media type strings. As a registry/client author, it's currently easy enough to hard-code these strings and special-case e.g. nondistributable layers or the compression algorithm; however, I can imagine that comparing hard-coded strings will become sub-optimal at some point in the future, and we'd be better off parsing these strings into a structured form.

  1. Any thoughts on whether we should try to follow that RFC? FWIW, there's a procedure for registering a suffix, if anyone wants to take a stab at adding +zstd.
  2. Is there blessed code anywhere for parsing OCI media types? Or is everyone just directly comparing these strings?

dattgoswami9lk5g added a commit to dattgoswami9lk5g/bremlinr that referenced this issue Jun 6, 2022
Closes: opencontainers/image-spec#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
7c00d pushed a commit to 7c00d/J1nHyeockKim that referenced this issue Jun 6, 2022
Closes: opencontainers/image-spec#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
7c00d added a commit to 7c00d/J1nHyeockKim that referenced this issue Jun 6, 2022
Closes: opencontainers/image-spec#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
laventuraw added a commit to laventuraw/Kihara-tony0 that referenced this issue Jun 6, 2022
Closes: opencontainers/image-spec#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
sudo-bmitch pushed a commit to sudo-bmitch/image-spec that referenced this issue Sep 25, 2022
Closes: opencontainers#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
tomalopbsr0tt added a commit to tomalopbsr0tt/fabiojosej that referenced this issue Oct 6, 2022
Closes: opencontainers/image-spec#787

Signed-off-by: Giuseppe Scrivano <gscrivan@redhat.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging a pull request may close this issue.

7 participants