Ci cache save if main only#4
Merged
Merged
Conversation
PR runs were producing one ~500 MB rust-cache entry per (job × rustc × Cargo.lock) tuple. With dependency churn across PRs the per-repo Actions cache budget grew to ~130 entries / ~65 GB, which trips eviction of warm main-scope entries and ultimately costs storage. PRs now still *restore* from existing caches (so they get the same speedup, ~3-5 min per job on a librdkafka cold build) but skip the save step, leaving cache writes to main only. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Lets in-flight design discussions live in the repo root as markdown without polluting git history. The current use is NOTES_DELIVERY_SEMANTICS.md, written locally as a shelf for the delivery-semantics + readiness redesign while sub-decisions (Skip semantics, commit-during-debounce concern) are still open. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
Builds on main are rarely reverted, so the next main build only ever reads from the most recent run's buildkit blobs. Per-commit layers from older runs are dead weight: they accumulate, content-address collisions make them hard to evict deliberately, and they push other caches (rust-cache, etc.) closer to GitHub's 10 GB per-repo ceiling until LRU starts evicting useful entries. The keep-top-N=200 heuristic survives one multi-arch build's ~30-50 blob writes plus 2-3x headroom; older entries get the `gh cache delete` treatment. PR runs are untouched (their entries are already capped by the rust-cache save-if change in the previous commit, and buildx writes are scoped per-ref). Needs `actions: write` on the image job so gh CLI can delete cache entries via the repo's API token. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com>
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.
No description provided.