Copilot commented on code in PR #15935:
URL: https://github.com/apache/grails-core/pull/15935#discussion_r3538976196
##########
.github/workflows/groovy-joint-workflow.yml:
##########
@@ -148,14 +151,15 @@ jobs:
- name: "🐘 Setup Gradle"
uses:
gradle/actions/setup-gradle@4d9f0ba0025fe599b4ebab900eb7f3a1d93ef4c2 # v5.0.0
with:
+ cache-disabled: true # this workflow rebuilds Groovy each run; a
Gradle home cache is not useful here
develocity-access-key: ${{ secrets.DEVELOCITY_ACCESS_KEY }}
- name: "🔍 Setup TestLens"
uses: testlens-app/setup-testlens@v1
- - name: "🗄️ Restore local Maven repository from cache"
- uses: actions/cache@v4
+ - name: "📥 Fetch the locally built Groovy artifacts"
+ uses: actions/[email protected]
with:
Review Comment:
actions/upload-artifact is pinned to v7.0.1 but the matching
actions/download-artifact step is pinned to v7.0.0. Keeping the upload/download
pair on the same version avoids subtle behavior mismatches and simplifies
future upgrades.
##########
.github/workflows/gradle.yml:
##########
@@ -36,9 +36,21 @@ jobs:
with:
distribution: liberica
java-version: 17
+ - name: "🗄️ Restore dependency jar cache"
+ uses: actions/cache@v4
+ with:
+ # Cache only downloaded dependency jars and wrapper distributions,
never Grails build outputs.
+ # Keyed by branch version so each release branch maintains its own
warm cache.
Review Comment:
Using actions/cache@v4 (restore+save) in every job can (1) save caches on
pull_request runs when the key misses (creating per-PR cache entries that are
not reusable and still consume quota) and (2) race on a cold branch where the
first job to finish saves an incomplete cache (e.g., validateDependencies),
preventing later jobs that download more dependencies from enriching it.
Consider switching to actions/cache/restore@v4 in all jobs, and adding a
single actions/cache/save@v4 step (conditioned on non-PR events) in one
dependency-heavy job after the build completes, using the same key.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]