ci: constrain cache e2e job modes - #1244
Merged
Merged
Conversation
Contributor
There was a problem hiding this comment.
Pull request overview
Updates the repository’s CI workflows to explicitly separate cache-producing jobs from cache-consuming/verification jobs, aiming to enforce cache read/write behavior at the GitHub Actions platform level during e2e and benchmark runs.
Changes:
- Add job-level
cache-mode: write-onlyto cache producer jobs so they always seed fresh entries without restoring. - Add job-level
cache-mode: readto restore/verification jobs so cache writes are blocked by platform enforcement. - Split the benchmark workflow into a
warm-caches(write-only) phase and abenchmark(read) phase to measure seeded restores only.
Show a summary per file
| File | Description |
|---|---|
| .github/workflows/e2e-cache.yml | Applies job-level cache access modes across the cache e2e matrix to distinguish producers vs consumers. |
| .github/workflows/benchmark-cache-restore.yml | Constrains warmup to cache writes and benchmarking to cache reads to isolate restore performance measurement. |
Review details
💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.
- Files reviewed: 2/2 changed files
- Comments generated: 2
- Review effort level: Lite
Comment on lines
25
to
+27
| name: Warm ${{ matrix.tool }} ${{ matrix.profile }} caches (${{ matrix.os }}) | ||
| runs-on: ${{ matrix.os }} | ||
| cache-mode: write-only |
Comment on lines
22
to
+24
| gradle-save: | ||
| runs-on: ${{ matrix.os }} | ||
| cache-mode: write-only |
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.
Description:
cache-mode: write-onlyon cache producer jobs so they populate fresh entries without consuming existing caches.cache-mode: readon restore and verification jobs so platform enforcement prevents cache writes.warm-cachesseeds fresh Maven and Gradle entries withwrite-only, whilebenchmarkmeasures only seeded restores withread.cache-read-only, to dogfood platform enforcement independently of setup-java API coverage.Check list:
npm run checklocally (format, lint, build, test) and all checks pass.