From a529a0430f9f5299a4e0969df30201a98b1610dc Mon Sep 17 00:00:00 2001 From: gabilang Date: Wed, 28 Jun 2023 08:41:43 +0530 Subject: [PATCH] Migrate to Java 17 --- .github/workflows/build-timestamped-master.yml | 8 ++++---- .github/workflows/central-publish.yml | 8 ++++---- .github/workflows/publish-release.yml | 8 ++++---- .github/workflows/pull-request.yml | 16 ++++++++-------- .github/workflows/trivy-scan.yml | 8 ++++---- .github/workflows/update_spec.yml | 2 +- README.md | 4 ++-- build-config/checkstyle/build.gradle | 4 ++-- gradle.properties | 14 +++++++------- gradle/wrapper/gradle-wrapper.properties | 2 +- native/build.gradle | 2 +- settings.gradle | 2 +- 12 files changed, 39 insertions(+), 39 deletions(-) diff --git a/.github/workflows/build-timestamped-master.yml b/.github/workflows/build-timestamped-master.yml index 2515f9465..e68b1d4eb 100644 --- a/.github/workflows/build-timestamped-master.yml +++ b/.github/workflows/build-timestamped-master.yml @@ -16,12 +16,12 @@ jobs: if: github.repository_owner == 'ballerina-platform' steps: - name: Checkout Repository - uses: actions/checkout@v2 - - name: Set up JDK 11 - uses: actions/setup-java@v2 + uses: actions/checkout@v3 + - name: Set up JDK 17 + uses: actions/setup-java@v3 with: distribution: 'temurin' - java-version: 11 + java-version: 17 - name: Change to Timestamped Version run: | startTime=$(TZ="Asia/Kolkata" date +'%Y%m%d-%H%M00') diff --git a/.github/workflows/central-publish.yml b/.github/workflows/central-publish.yml index a3434c3e5..e7236a4ee 100644 --- a/.github/workflows/central-publish.yml +++ b/.github/workflows/central-publish.yml @@ -17,12 +17,12 @@ jobs: runs-on: ubuntu-latest if: github.repository_owner == 'ballerina-platform' steps: - - uses: actions/checkout@v2 - - name: Set up JDK 11 - uses: actions/setup-java@v2 + - uses: actions/checkout@v3 + - name: Set up JDK 17 + uses: actions/setup-java@v3 with: distribution: 'temurin' - java-version: 11 + java-version: 17 - name: Build with Gradle env: packageUser: ${{ github.actor }} diff --git a/.github/workflows/publish-release.yml b/.github/workflows/publish-release.yml index a52b7d458..31659f9ec 100644 --- a/.github/workflows/publish-release.yml +++ b/.github/workflows/publish-release.yml @@ -10,12 +10,12 @@ jobs: runs-on: ubuntu-latest if: github.repository_owner == 'ballerina-platform' steps: - - uses: actions/checkout@v2 - - name: Set up JDK 11 - uses: actions/setup-java@v2 + - uses: actions/checkout@v3 + - name: Set up JDK 17 + uses: actions/setup-java@v3 with: distribution: 'temurin' - java-version: 11 + java-version: 17 - name: Build with Gradle env: packageUser: ${{ github.actor }} diff --git a/.github/workflows/pull-request.yml b/.github/workflows/pull-request.yml index 8c81c44f5..f0f4ac82c 100644 --- a/.github/workflows/pull-request.yml +++ b/.github/workflows/pull-request.yml @@ -8,12 +8,12 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout Repository - uses: actions/checkout@v2 - - name: Set up JDK 11 - uses: actions/setup-java@v2 + uses: actions/checkout@v3 + - name: Set up JDK 17 + uses: actions/setup-java@v3 with: distribution: 'temurin' - java-version: 11 + java-version: 17 - name: Build with Gradle env: packageUser: ${{ github.actor }} @@ -30,12 +30,12 @@ jobs: runs-on: windows-latest steps: - name: Checkout Repository - uses: actions/checkout@v2 - - name: Set up JDK 11 - uses: actions/setup-java@v2 + uses: actions/checkout@v3 + - name: Set up JDK 17 + uses: actions/setup-java@v3 with: distribution: 'temurin' - java-version: 11 + java-version: 17 - name: Build with Gradle env: packageUser: ${{ github.actor }} diff --git a/.github/workflows/trivy-scan.yml b/.github/workflows/trivy-scan.yml index 3e3b3389d..fb502e612 100644 --- a/.github/workflows/trivy-scan.yml +++ b/.github/workflows/trivy-scan.yml @@ -10,12 +10,12 @@ jobs: name: Build on Ubuntu runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - name: Set up JDK 11 - uses: actions/setup-java@v2 + - uses: actions/checkout@v3 + - name: Set up JDK 17 + uses: actions/setup-java@v3 with: distribution: 'temurin' - java-version: 11 + java-version: 17 - name: Build with Gradle env: packageUser: ${{ github.actor }} diff --git a/.github/workflows/update_spec.yml b/.github/workflows/update_spec.yml index 3af6d4a4b..7815278d0 100644 --- a/.github/workflows/update_spec.yml +++ b/.github/workflows/update_spec.yml @@ -19,7 +19,7 @@ jobs: steps: - name: Checkout Repository - uses: actions/checkout@v2 + uses: actions/checkout@v3 - name: Get current date id: date diff --git a/README.md b/README.md index dd1e9448d..a31db20cd 100644 --- a/README.md +++ b/README.md @@ -345,9 +345,9 @@ This repository only contains the source code for the module. ### Set Up the prerequisites -* Download and install Java SE Development Kit (JDK) version 11 (from one of the following locations). +* Download and install Java SE Development Kit (JDK) version 17 (from one of the following locations). - * [Oracle](https://www.oracle.com/java/technologies/javase-jdk11-downloads.html) + * [Oracle](https://www.oracle.com/java/technologies/javase-jdk17-downloads.html) * [OpenJDK](https://adoptium.net/) diff --git a/build-config/checkstyle/build.gradle b/build-config/checkstyle/build.gradle index b89ab41fe..1dbe8db0c 100644 --- a/build-config/checkstyle/build.gradle +++ b/build-config/checkstyle/build.gradle @@ -23,8 +23,8 @@ apply plugin: 'java' task downloadCheckstyleRuleFiles(type: Download) { src([ - 'https://raw.githubusercontent.com/wso2/code-quality-tools/v1.3/checkstyle/checkstyle.xml', - 'https://raw.githubusercontent.com/wso2/code-quality-tools/v1.3/checkstyle/suppressions.xml' + 'https://raw.githubusercontent.com/wso2/code-quality-tools/v1.4/checkstyle/jdk-17/checkstyle.xml', + 'https://raw.githubusercontent.com/wso2/code-quality-tools/v1.4/checkstyle/jdk-17/suppressions.xml' ]) overwrite false onlyIfNewer true diff --git a/gradle.properties b/gradle.properties index d23573fce..ec9597434 100644 --- a/gradle.properties +++ b/gradle.properties @@ -4,7 +4,7 @@ version=1.9.0-SNAPSHOT #dependency versions ballerinaLangVersion= 2201.7.0-20230622-064700-4a2dc6dd ballerinaTomlParserVersion=1.2.2 -checkstylePluginVersion=8.18 +checkstylePluginVersion=10.12.0 commonsLang3Version=3.8.1 slf4jVersion=1.7.30 protoGoogleCommonsVersion=1.17.0 @@ -13,13 +13,13 @@ jknackHandlebarsVersion=4.0.6 nettyVersion=4.1.94.Final nettyTcnativeVersion=2.0.61.Final picocliVersion=4.0.1 -githubSpotbugsVersion=4.0.5 -githubJohnrengelmanShadowVersion=5.2.0 -underCouchDownloadVersion=4.0.4 +githubSpotbugsVersion=5.0.14 +githubJohnrengelmanShadowVersion=8.1.0 +underCouchDownloadVersion=5.4.0 researchgateReleaseVersion=2.8.0 -testngVersion=7.4.0 -mockitoVersion=3.7.7 -jacocoVersion=0.8.8 +testngVersion=7.6.1 +mockitoVersion=5.3.1 +jacocoVersion=0.8.10 wso2OrbitAntlrVersion=4.5.1.wso2v1 ballerinaGradlePluginVersion=1.1.0 bouncycastleVersion=1.69 diff --git a/gradle/wrapper/gradle-wrapper.properties b/gradle/wrapper/gradle-wrapper.properties index 69a971507..fae08049a 100644 --- a/gradle/wrapper/gradle-wrapper.properties +++ b/gradle/wrapper/gradle-wrapper.properties @@ -1,5 +1,5 @@ distributionBase=GRADLE_USER_HOME distributionPath=wrapper/dists -distributionUrl=https\://services.gradle.org/distributions/gradle-7.1-bin.zip +distributionUrl=https\://services.gradle.org/distributions/gradle-8.1.1-bin.zip zipStoreBase=GRADLE_USER_HOME zipStorePath=wrapper/dists diff --git a/native/build.gradle b/native/build.gradle index 1e1c6348e..a46c28c37 100644 --- a/native/build.gradle +++ b/native/build.gradle @@ -75,7 +75,7 @@ jacoco { jacocoTestReport { dependsOn test reports { - xml.enabled true + xml.required = true } } diff --git a/settings.gradle b/settings.gradle index f8c53ef9e..acb85a52d 100644 --- a/settings.gradle +++ b/settings.gradle @@ -8,7 +8,7 @@ */ plugins { - id "com.gradle.enterprise" version "3.2" + id "com.gradle.enterprise" version "3.13.2" } rootProject.name = 'grpc'