Skip to content
This repository was archived by the owner on Nov 19, 2026. It is now read-only.

vendor: use github.com/klauspost/pgzip instead of compress/gzip - #543

Merged
vrothberg merged 2 commits into
containers:masterfrom
giuseppe:use-optimized-gzip
Dec 18, 2018
Merged

vrothberg merged 2 commits into
containers:masterfrom
giuseppe:use-optimized-gzip

Conversation

@giuseppe

Copy link
Copy Markdown
Member

from my tests, I've seen a net improvement of around 30% on the wall
clock time in decompressing layers.

Signed-off-by: Giuseppe Scrivano [email protected]

@vrothberg

Copy link
Copy Markdown
Member

Awesome, LGTM.

Just one request for the commit message. Could you add some info which additional packages need to be vendored by users of containers/image:

github.com/klauspost/pgzip v1.2.1
github.com/klauspost/compress v1.4.1
github.com/klauspost/cpuid v1.2.0

This will hopefully make vendoring containers/image easier.

@giuseppe

Copy link
Copy Markdown
Member Author

let's not merge yet. I will prepare a WIP PR for Skopeo that uses this PR (as well as the coming PR for containers/storage) so we can play better with it

@rhatdan

rhatdan commented Dec 13, 2018

Copy link
Copy Markdown
Member

Nice work @giuseppe

@giuseppe

Copy link
Copy Markdown
Member Author

WIP PR for skopeo here: podman-container-tools/skopeo#572

@mrunalp

mrunalp commented Dec 13, 2018

Copy link
Copy Markdown
Contributor

I think we should put all this into a CRI-O PR and make sure the e2e pass :)

@giuseppe

Copy link
Copy Markdown
Member Author

I think we should put all this into a CRI-O PR and make sure the e2e pass :)

yes sir! Done here: cri-o/cri-o#1963 :-)

Signed-off-by: Giuseppe Scrivano <[email protected]>
@giuseppe
giuseppe force-pushed the use-optimized-gzip branch 3 times, most recently from 8687719 to 75fee2e Compare December 14, 2018 10:42
@giuseppe

Copy link
Copy Markdown
Member Author

it fails to build Skopeo as Skopeo is not yet vendoring "github.com/klauspost/pgzip"

@vrothberg

Copy link
Copy Markdown
Member

LGTM (podman-container-tools/skopeo#572 passed)

@rhatdan

rhatdan commented Dec 15, 2018

Copy link
Copy Markdown
Member

LGTM, lets merge since this passes the CRI-O Tests.

@rhatdan

rhatdan commented Dec 15, 2018

Copy link
Copy Markdown
Member

@giuseppe tests are failing?

@vrothberg

Copy link
Copy Markdown
Member

@giuseppe tests are failing?

That's because the CI uses Skopeo for testing which doesn't yet vendor the pgzip library. However, podman-container-tools/skopeo#572 passes so we can safely merge this branch.

@mtrmac mtrmac left a comment

Copy link
Copy Markdown
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

ACK overall. (Please merge this and a re-vendored version podman-container-tools/skopeo#572 together to make sure the tests don’t get out of sync.)

Comment thread .travis.yml Resolved
Comment thread vendor.conf Resolved
Comment thread copy/copy.go Resolved
from my tests, I've seen a net improvement of around 30% on the wall
clock time in decompressing layers.

Signed-off-by: Giuseppe Scrivano <[email protected]>
@vrothberg

Copy link
Copy Markdown
Member

LGTM

@vrothberg

Copy link
Copy Markdown
Member

@giuseppe @rhatdan I think we can merge this one and start the usual vendor marathon in the tools.

@TomSweeneyRedHat

Copy link
Copy Markdown
Member

@vrothberg tests aren't too happy :^(

go build "-buildmode=pie" -ldflags "-X main.gitCommit=a51e38e60d34a595bde0df06f1d39853cc04a5de" -gcflags "" -tags "btrfs_noversion libdm_no_deferred_remove" -o skopeo ./cmd/skopeo
vendor/github.com/containers/image/pkg/compression/compression.go:9:2: cannot find package "github.com/klauspost/pgzip" in any of:
	/tmp/tmp.rSecZe78dh/src/github.com/containers/skopeo/vendor/github.com/klauspost/pgzip (vendor tree)
	/usr/local/go/src/github.com/klauspost/pgzip (from $GOROOT)
	/tmp/tmp.rSecZe78dh/src/github.com/klauspost/pgzip (from $GOPATH)
Makefile:83: recipe for target 'binary-local' failed
make[1]: *** [binary-local] Error 1
make[1]: Leaving directory '/tmp/tmp.rSecZe78dh/src/github.com/containers/skopeo'
Makefile:69: recipe for target 'test-skopeo' failed
make: *** [test-skopeo] Error 2

@vrothberg

Copy link
Copy Markdown
Member

@vrothberg tests aren't too happy :^(

That's because the CI uses Skopeo which does not yet have this change vendored. It's a bit of a chicken-egg problem for such changes in c/image. @giuseppe opened a PR at Skopeo to check whether it likes this one here: podman-container-tools/skopeo#572

As podman-container-tools/skopeo#572 is green, I think we can merge it.

@vrothberg

Copy link
Copy Markdown
Member

Merging (agreed with @giuseppe).

@vrothberg vrothberg closed this Dec 18, 2018
@vrothberg vrothberg reopened this Dec 18, 2018
@vrothberg
vrothberg merged commit dea720b into containers:master Dec 18, 2018
mtrmac added a commit to mtrmac/image that referenced this pull request Jan 2, 2019
This reverts commit a5c3a7f.

Per containers#543 (comment) ,
this was not actually necessary, so let's not keep it around as
a riddle for future readers / an artifact for copy&pasting into
other projects.

Signed-off-by: Miloslav Trmač <[email protected]>
Silvanoc pushed a commit to Silvanoc/image that referenced this pull request Jan 17, 2019
This reverts commit a5c3a7f.

Per containers#543 (comment) ,
this was not actually necessary, so let's not keep it around as
a riddle for future readers / an artifact for copy&pasting into
other projects.

Signed-off-by: Miloslav Trmač <[email protected]>
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

6 participants