Skip to content
This repository has been archived by the owner on Jun 5, 2024. It is now read-only.

Start gunzipping ahead of time #85

Merged
merged 1 commit into from
Jul 11, 2023

Conversation

jonjohnsonjr
Copy link
Contributor

Since we serialize installPackage, we just kind of spin doing nothing once we've expanded all the APKs. For large APKs, we are currently bottlenecked by gzip. We could cache the uncompressed tarballs, but that would eat up a bunch of disk space (which is currently a pain point).

Instead, this starts decompressing as soon as we've finished expanding APKs so that we can overlap that work with installing prerequisite packages.

This shaves about 500ms off warm cache and 1.5s off cold cache.

Since we serialize installPackage, we just kind of spin doing nothing
once we've expanded all the APKs. For large APKs, we are currently
bottlenecked by gzip. We could cache the uncompressed tarballs, but that
would eat up a bunch of disk space (which is currently a pain point).

Instead, this starts decompressing as soon as we've finished expanding
APKs so that we can overlap that work with installing prerequisite
packages.

Signed-off-by: Jon Johnson <jon.johnson@chainguard.dev>
@imjasonh imjasonh merged commit 57105dd into chainguard-dev:main Jul 11, 2023
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.

2 participants