Skip to content

Commit

Permalink
Update Github workflow with JDK21 (#927)
Browse files Browse the repository at this point in the history
**Motivation**
Since Java 21 is an LTS version released on September 19, 2023. We should update the CI Github build.

Result
Close #911
  • Loading branch information
thachlp committed May 10, 2024
1 parent f1f17af commit adb71ab
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 8 deletions.
10 changes: 5 additions & 5 deletions .github/workflows/actions_build.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ concurrency:

env:
LC_ALL: "en_US.UTF-8"
BUILD_JDK_VERSION: "17"
BUILD_JDK_VERSION: "21"

jobs:
build:
Expand All @@ -28,7 +28,7 @@ jobs:
fail-fast: false
matrix:
os: [ubuntu-latest, macos-12, windows-latest]
java: [17]
java: [21]
include:
- java: 8
os: ubuntu-latest
Expand All @@ -40,22 +40,22 @@ jobs:
- java: 17
os: ubuntu-latest
min-java: 11
- java: 19
- java: 21
os: ubuntu-latest
steps:
- uses: actions/checkout@v3

- id: setup-build-jdk
name: Set up build JDK ${{ env.BUILD_JDK_VERSION }}
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: ${{ env.BUILD_JDK_VERSION }}

- id: setup-test-jdk
if: ${{ matrix.java != env.BUILD_JDK_VERSION }}
name: Set up test JDK ${{ matrix.java }}
uses: actions/setup-java@v3
uses: actions/setup-java@v4
with:
distribution: 'temurin'
java-version: ${{ matrix.java }}
Expand Down
4 changes: 2 additions & 2 deletions build.gradle
Original file line number Diff line number Diff line change
Expand Up @@ -138,9 +138,9 @@ allprojects {
}
}

// Require to use JDK 17 when releasing.
// Require to use JDK 21 when releasing.
tasks.release.doFirst {
if (JavaVersion.current() != JavaVersion.VERSION_17) {
if (JavaVersion.current() != JavaVersion.VERSION_21) {
throw new IllegalStateException("You must release using JDK 17.")
}
}
2 changes: 1 addition & 1 deletion dependencies.toml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ mockito = "4.11.0"
nexus-publish-plugin = "2.0.0"
node-gradle-plugin = "7.0.2"
osdetector = "1.7.3"
proguard = "7.3.1"
proguard = "7.4.2"
quartz = "2.3.2"
shadow-gradle-plugin = "7.1.2"
shiro = "1.3.2"
Expand Down

0 comments on commit adb71ab

Please sign in to comment.