Skip to content

UniversalPackages: Add incrementality to avoid re-downloading packages#639

Merged
dfederm merged 1 commit intomainfrom
upack-caching
Aug 15, 2025
Merged

UniversalPackages: Add incrementality to avoid re-downloading packages#639
dfederm merged 1 commit intomainfrom
upack-caching

Conversation

@dfederm
Copy link
Member

@dfederm dfederm commented Aug 15, 2025

This change avoids downloading a universal package if the destination path already exists.

However, to combat scenarios where the package didn't download successfully (eg. a cancelled/killed restore), the path used to download the package is mapped to a temporary location then moved atomically when successful.

Here is an example showing the difference, although this example is using an extremely trivial package. A much larger package (which is where universal package shine to begin with) would produce a much more significant difference in absolute numbers.

Before:
Build 1:
image

Build 2:
image

After:
Build 1:
image

Build 2:
image

@dfederm dfederm enabled auto-merge (squash) August 15, 2025 23:06
@dfederm dfederm disabled auto-merge August 15, 2025 23:15
@dfederm dfederm merged commit 97715ca into main Aug 15, 2025
5 checks passed
@dfederm dfederm deleted the upack-caching branch August 15, 2025 23:15
Copy link
Collaborator

@erikmav erikmav left a comment

Choose a reason for hiding this comment

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

LGTM

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 this pull request may close these issues.

3 participants