Skip to content

Commit

Permalink
Use JDK version as part of the cache key.
Browse files Browse the repository at this point in the history
Signed-off-by: dblock <dblock@amazon.com>
  • Loading branch information
dblock committed Feb 6, 2025
1 parent ab102de commit 85c437a
Showing 1 changed file with 4 additions and 5 deletions.
9 changes: 4 additions & 5 deletions .github/workflows/test-unreleased.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,12 +3,12 @@ name: Integration with Unreleased OpenSearch
on:
push:
branches:
- "main"
- 'main'
paths-ignore:
- '*.md'
pull_request:
branches:
- "main"
- 'main'
paths-ignore:
- '*.md'

Expand All @@ -24,7 +24,7 @@ jobs:
entry:
- { ruby_version: '3.3', opensearch_ref: '1.x', jdk_version: '11' }
- { ruby_version: '3.3', opensearch_ref: '2.x', jdk_version: '17' }
- { ruby_version: '3.3', opensearch_ref: 'main', jdk_version: '23' }
- { ruby_version: '3.3', opensearch_ref: 'main', jdk_version: '21' }

steps:
- uses: ruby/setup-ruby@v1
Expand All @@ -40,7 +40,7 @@ jobs:
- name: Get OpenSearch branch top
id: get-key
working-directory: opensearch
run: echo key=`git log -1 --format='%H'` >> $GITHUB_OUTPUT
run: echo key=`git log -1 --format='%H'`-${{ matrix.entry.jdk_version }} >> $GITHUB_OUTPUT

- name: Restore cached build
id: cache-restore
Expand All @@ -60,7 +60,6 @@ jobs:
if: steps.cache-restore.outputs.cache-hit != 'true'
working-directory: opensearch
run: ./gradlew :distribution:archives:linux-tar:assemble --stacktrace


- name: Save cached build
if: steps.cache-restore.outputs.cache-hit != 'true'
Expand Down

0 comments on commit 85c437a

Please sign in to comment.