Repository navigation
ci(release): share one small toolchain cache, stop refetching libraries - #59
Merged
Merged
Conversation
Measured over the 23 release runs so far: 1.83 TB of toolchain restores (about 1.06 GB each), 264 tool downloads, 2,338 library clones, and a library cache that hit exactly in 17 of 1,711 board jobs. The keys hashed every variant file, so each branch saved its own ~5 GB of identical toolchains and the 10 GB limit evicted them, and the libraries, again. - Toolchain key: platform, packages and the distinct board requirements of the whole project. Five caches serve every firmware set and all branches. - Leave the download archives out of it; the tools are already unpacked. - The warm-up installs one env per distinct requirement instead of every env of the set, and does not even check the repository out on a hit. - Replace the .pio/libdeps cache (tens of MB per board) by the library archives and git mirrors, a few MB per batch, refreshed weekly. Libraries are unpacked for every build, so an in-repo library such as AsyncElegantOTA can no longer come from another commit's cache.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Reworks the caches of the DMC Firmware Release workflow so runs share one small set of toolchains and stop refetching what they already have. One file changed.
Why
Measured from the logs of the 23 release runs so far:
The keys hashed every variant file, so each branch saved its own copy of about 5 GB of identical toolchains. Three branches exceed the 10 GB limit, so they evicted each other's caches and the libraries. Each copy also held the download archives of tools that were already unpacked in it.
#55 (batching) lowers the number of restores but not this: its library cache would have overflowed the same way.
What changes
pio-tc-v2): keyed on platform, packages and the distinct board requirements of the whole project. Five caches serve all eight firmware sets and all three branches. Download archives are left out.pio-dl-v2): the.pio/libdepscache is replaced by the library archives plus git mirrors of one batch, keyed by content and week. Anything over 20 MB is kept out.AsyncElegantOTA(it differs betweendmc-devanddmc-observer-dev) through its restore-keys.Testing
build_flagsedit changes no key, a platform bump changes exactly one toolchain key, a new library changes at most one library key.Not tested:
companion-observerondev(5 boards; replaces that dev release).Notes for review
nordicnrf52is not pinned inplatformio.ini, so its version stays as cached until that cache is evicted or its key changes.queue(from ci: own-repository workflows only, batched release builds #55) as unknown; it is a documented GitHub setting newer than that release.