From 22560cc64cbe04f6d10240aaae7674d7dd9c92ce Mon Sep 17 00:00:00 2001 From: sohyun-ku Date: Fri, 26 Jul 2024 15:35:18 +0900 Subject: [PATCH] Bump up Java 21 --- .github/workflows/build-develop.yml | 8 ++++---- .github/workflows/build-main.yml | 2 +- .github/workflows/release.yml | 2 +- build.gradle.kts | 1 + doc/installation.md | 2 +- scavenger-api/build.gradle.kts | 2 +- scavenger-collector/build.gradle.kts | 2 +- scavenger-demo-extension/build.gradle.kts | 2 +- scavenger-demo/build.gradle.kts | 2 +- scavenger-entity/build.gradle.kts | 2 +- scavenger-old-agent-java/build.gradle.kts | 3 +++ scavenger-old-model/build.gradle.kts | 6 ++++++ 12 files changed, 22 insertions(+), 12 deletions(-) diff --git a/.github/workflows/build-develop.yml b/.github/workflows/build-develop.yml index 00b200d6..ec24a010 100644 --- a/.github/workflows/build-develop.yml +++ b/.github/workflows/build-develop.yml @@ -22,7 +22,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: 'zulu' - java-version: '17' + java-version: '21' - name: Gradle Caching uses: actions/cache@v3 with: @@ -48,7 +48,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: 'zulu' - java-version: '17' + java-version: '21' - name: Gradle Caching uses: actions/cache@v3 with: @@ -74,7 +74,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: 'zulu' - java-version: '17' + java-version: '21' - name: Gradle Caching uses: actions/cache@v3 with: @@ -115,7 +115,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: 'zulu' - java-version: '17' + java-version: '21' - name: Gradle Caching uses: actions/cache@v3 with: diff --git a/.github/workflows/build-main.yml b/.github/workflows/build-main.yml index 5e1e6558..e026a21e 100644 --- a/.github/workflows/build-main.yml +++ b/.github/workflows/build-main.yml @@ -13,7 +13,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: 'zulu' - java-version: '17' + java-version: '21' - name: Gradle Caching uses: actions/cache@v3 with: diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index b7c679e4..8c613f8c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -17,7 +17,7 @@ jobs: uses: actions/setup-java@v3 with: distribution: 'zulu' - java-version: '17' + java-version: '21' - name: Extract tag version run: echo "tag=$(echo '${{ github.ref_name }}' | egrep -o '[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}(-p[0-9]+)?')" >> $GITHUB_OUTPUT id: extract_tag_version diff --git a/build.gradle.kts b/build.gradle.kts index 87f353a4..4fa8b9cf 100644 --- a/build.gradle.kts +++ b/build.gradle.kts @@ -1,6 +1,7 @@ plugins { idea id("net.researchgate.release") version "3.0.2" + kotlin("jvm") version "1.9.24" apply false } allprojects { diff --git a/doc/installation.md b/doc/installation.md index 7c11ffc1..1372cce4 100644 --- a/doc/installation.md +++ b/doc/installation.md @@ -3,7 +3,7 @@ ## Prerequisite - Scavenger is a combination of various server components(API, Frontend, Collector) and agent component. - To install scavenger, you need JDK 17 or latest version. + To install scavenger, you need JDK 21 or latest version. - Scavenger uses 2 ports. if some ports are blocked by your firewall, you should ask the network admin to open the following ports in the firewall. These ports can be configured by the configuration. diff --git a/scavenger-api/build.gradle.kts b/scavenger-api/build.gradle.kts index 73a416a4..ed129124 100644 --- a/scavenger-api/build.gradle.kts +++ b/scavenger-api/build.gradle.kts @@ -54,7 +54,7 @@ configure { } kotlin { - jvmToolchain(17) + jvmToolchain(21) } tasks.withType { diff --git a/scavenger-collector/build.gradle.kts b/scavenger-collector/build.gradle.kts index a6649579..4ca9f36b 100644 --- a/scavenger-collector/build.gradle.kts +++ b/scavenger-collector/build.gradle.kts @@ -69,7 +69,7 @@ configure { } kotlin { - jvmToolchain(17) + jvmToolchain(21) } tasks.withType { diff --git a/scavenger-demo-extension/build.gradle.kts b/scavenger-demo-extension/build.gradle.kts index 87001465..3676d585 100644 --- a/scavenger-demo-extension/build.gradle.kts +++ b/scavenger-demo-extension/build.gradle.kts @@ -15,7 +15,7 @@ dependencies { } kotlin { - jvmToolchain(17) + jvmToolchain(21) } tasks.withType { diff --git a/scavenger-demo/build.gradle.kts b/scavenger-demo/build.gradle.kts index 82ab2387..d3dcc28d 100644 --- a/scavenger-demo/build.gradle.kts +++ b/scavenger-demo/build.gradle.kts @@ -29,7 +29,7 @@ dependencies { } kotlin { - jvmToolchain(17) + jvmToolchain(21) } tasks.withType { diff --git a/scavenger-entity/build.gradle.kts b/scavenger-entity/build.gradle.kts index 362f4060..75b3f453 100644 --- a/scavenger-entity/build.gradle.kts +++ b/scavenger-entity/build.gradle.kts @@ -13,7 +13,7 @@ dependencies { java { toolchain { - languageVersion.set(JavaLanguageVersion.of(17)) + languageVersion.set(JavaLanguageVersion.of(21)) } } diff --git a/scavenger-old-agent-java/build.gradle.kts b/scavenger-old-agent-java/build.gradle.kts index 50425453..80716ada 100644 --- a/scavenger-old-agent-java/build.gradle.kts +++ b/scavenger-old-agent-java/build.gradle.kts @@ -36,6 +36,9 @@ dependencies { java { withJavadocJar() withSourcesJar() + toolchain { + languageVersion.set(JavaLanguageVersion.of(8)) + } } tasks.compileJava { diff --git a/scavenger-old-model/build.gradle.kts b/scavenger-old-model/build.gradle.kts index 452fefe3..2eeb8d75 100644 --- a/scavenger-old-model/build.gradle.kts +++ b/scavenger-old-model/build.gradle.kts @@ -15,6 +15,12 @@ dependencies { testImplementation("org.hamcrest:hamcrest:2.2") } +java { + toolchain { + languageVersion.set(JavaLanguageVersion.of(8)) + } +} + tasks.compileJava { sourceCompatibility = "7" targetCompatibility = "7"