-
Notifications
You must be signed in to change notification settings - Fork 821
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Better local caching via burrunan/gradle-cache-action #1054
Changes from 2 commits
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -28,20 +28,14 @@ jobs: | |
with: | ||
java-version: 11 | ||
|
||
- name: Cache gradle dependencies | ||
- name: Test | ||
uses: burrunan/gradle-cache-action@v1 | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Looks like gradle-caching-runner or the like will be a good name. Not surprising to see the best caching comes with having full visibility to Gradle. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Naming is hard :) I see JUnit team uses the following, and it can't be folded to a single command, so I'm exploring ways to allow multiple (Gradle? Shell?) commands to be executed (to avoid copy-paste the boring run: |
./gradlew --version
./gradlew build |
||
with: | ||
job-id: jdk${{ matrix.java }} | ||
|
||
- name: Test with Gradle | ||
uses: nick-invision/retry@v1 | ||
env: | ||
S3_BUILD_CACHE_ACCESS_KEY_ID: ${{ secrets.S3_BUILD_CACHE_ACCESS_KEY_ID }} | ||
S3_BUILD_CACHE_SECRET_KEY: ${{ secrets.S3_BUILD_CACHE_SECRET_KEY }} | ||
with: | ||
command: ./gradlew testJava${{ matrix.java }} --stacktrace | ||
timeout_minutes: 60 | ||
max_attempts: 3 | ||
job-id: jdk${{ matrix.java }} | ||
arguments: testJava${{ matrix.java }} --stacktrace -Dorg.gradle.caching.debug=true | ||
iNikem marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
- name: Aggregate test reports with ciMate | ||
if: always() | ||
|
@@ -63,20 +57,14 @@ jobs: | |
with: | ||
java-version: 11 | ||
|
||
- name: Cache gradle dependencies | ||
- name: Test | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Similarly how about |
||
uses: burrunan/gradle-cache-action@v1 | ||
with: | ||
job-id: latestDepTest | ||
|
||
- name: Test with Gradle | ||
uses: nick-invision/retry@v1 | ||
env: | ||
S3_BUILD_CACHE_ACCESS_KEY_ID: ${{ secrets.S3_BUILD_CACHE_ACCESS_KEY_ID }} | ||
S3_BUILD_CACHE_SECRET_KEY: ${{ secrets.S3_BUILD_CACHE_SECRET_KEY }} | ||
with: | ||
command: ./gradlew test -PtestLatestDeps=true --stacktrace | ||
timeout_minutes: 60 | ||
max_attempts: 3 | ||
arguments: test -PtestLatestDeps=true --stacktrace | ||
iNikem marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
- name: Aggregate test reports with ciMate | ||
if: always() | ||
|
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -24,17 +24,14 @@ jobs: | |
with: | ||
java-version: 11 | ||
|
||
- name: Cache gradle dependencies | ||
- name: Test | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Ditto |
||
uses: burrunan/gradle-cache-action@v1 | ||
env: | ||
S3_BUILD_CACHE_ACCESS_KEY_ID: ${{ secrets.S3_BUILD_CACHE_ACCESS_KEY_ID }} | ||
S3_BUILD_CACHE_SECRET_KEY: ${{ secrets.S3_BUILD_CACHE_SECRET_KEY }} | ||
with: | ||
job-id: jdk${{ matrix.java }} | ||
|
||
- name: Test with Gradle | ||
uses: nick-invision/retry@v1 | ||
with: | ||
command: ./gradlew testJava${{ matrix.java }} --stacktrace | ||
timeout_minutes: 60 | ||
max_attempts: 3 | ||
arguments: testJava${{ matrix.java }} --stacktrace | ||
iNikem marked this conversation as resolved.
Show resolved
Hide resolved
|
||
|
||
- name: Aggregate test reports with ciMate | ||
if: always() | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
While we're here how about
Test on ${{matrix.java}}
?There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We already have in job name. Isn't it enough?