Skip to content

Commit f5deaaf

Browse files
committed
Bump actions/setup-java to v3.14.1 with adopt distribution
The setup-build-environment composite action was pinned to actions/setup-java@v1.4.4 (Aug 2020). On arm64 macos-latest runners (Image: macos-15-arm64) v1.4.4 resolves JDKs under the legacy x64-only tool cache path and intermittently fails with: JAVA_HOME: /Users/runner/hostedtoolcache/jdk/8.0.492/x64 The JAVA_HOME environment variable is not defined correctly, this environment variable is needed to run this program. Observed on PR #773 run 24765873049, jobs unit-tests (macos-latest, 8), (macos-latest, 11), and (macos-latest, 17). Java 20 on the same commit passed, and the same workflow on the same commit SHA has alternated between pass and fail, confirming the x64/arm64 mismatch is the root cause. release.yml and package.yml already use v3.14.1 with distribution: "adopt"; this change aligns setup-build-environment with them. Co-authored-by: Isaac
1 parent 17f558c commit f5deaaf

1 file changed

Lines changed: 2 additions & 1 deletion

File tree

.github/actions/setup-build-environment/action.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -19,9 +19,10 @@ runs:
1919
oidc-provider-name: github-actions
2020

2121
- name: Set up JDK
22-
uses: actions/setup-java@b6e674f4b717d7b0ae3baee0fbe79f498905dfde # v1.4.4
22+
uses: actions/setup-java@17f84c3641ba7b8f6deff6309fc4c864478f5d62 # v3.14.1
2323
with:
2424
java-version: ${{ inputs.java-version }}
25+
distribution: "adopt"
2526

2627
- name: Configure Maven for JFrog
2728
if: runner.os != 'macOS'

0 commit comments

Comments
 (0)