-
Notifications
You must be signed in to change notification settings - Fork 98
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
*: improve performance #339
Comments
It looks like a lot of the time is spent in decompression (which is sadly single-threaded and is the same as stock I guess this mirrors what you've seen @tych0? |
Yeah, exactly. Ideally we wouldn't really need mtree at all :) |
Or maybe modernize on zstd? I'm working on moving us to a parallel-extraction overlayfs no-mtree model right now to get rid of this problem, so I don't think we're so worried about which compression algorithm we'll use. |
While we can (and should) add support for zstd -- the issue is that most other image builders aren't producing zstd images (and others' don't support zstd yet) so we're going to have performance issues with decompression for at least a little while longer. For umoci I'd propose we add a new |
Regarding the cost of But parallel extraction combined with overlayfs is also what we ended up using for our solution :) |
@cyphar is there anything actionable here for a new contributor? I'm using umoci as the base for an OCI plugin in the Pants build system, and unpack/repack is a substantial portion of many build steps. Just not sure where to start in this codebase... |
@tgolsson I'm not sure if there's a nice place to start necessarily. I think the best performance improvement we could make here is if we generate the mtree tree during unpack (meaning we create a "fake" tree, eliminating the need for
The slightly annoying thing is that Honestly, it's probably simpler for me to take a crack at this. I wasn't sure if this was still an issue for most people so I didn't set aside any time to work on it (and I've been busy with other projects recently). |
But if you would like to help, taking a look at the |
FWIW, I have since figured out and fixed the issues in go-mtree (vbatts/go-mtree#188 fixes the relevant issues for us to be able to use the FullType version of the manifest -- meaning we can generate the manifest with a per-full-path map first during unpacking and splat out a manifest at the end). |
Currently umoci (especially
umoci unpack
) is less sprightly than would be ideal. Some of this is a natural result of working with tar archives (which disallow parallelism during extraction) but it feels like we should be able to extract things much more quickly.go-mtree
generation is also quite expensive so maybe we should consider generating it during extraction (though the concept has scared me in the past).But it would also be nice to have pprof profiles be generated as part of the test suite so we can get a better idea of where the slow points are.
The text was updated successfully, but these errors were encountered: