This is an automated email from the ASF dual-hosted git repository.
zrlw pushed a commit to branch 3.3
in repository https://gitbox.apache.org/repos/asf/dubbo.git
The following commit(s) were added to refs/heads/3.3 by this push:
new f83f654e0c Add multi-JDK testing support to PR workflow (#15542)
f83f654e0c is described below
commit f83f654e0c0f53931e4d2e31ba75214783e7f549
Author: Eric Wang <[email protected]>
AuthorDate: Tue Jul 15 08:25:32 2025 +0800
Add multi-JDK testing support to PR workflow (#15542)
* Set unit java testing matrix to 8,11,17,21
* Update integration and samples java testing matrix from 8,17 to 8,21
---------
Co-authored-by: Rain Yu <[email protected]>
Co-authored-by: zrlw <[email protected]>
---
.github/workflows/build-and-test-pr.yml | 33 +++++++++++++++++++++------------
1 file changed, 21 insertions(+), 12 deletions(-)
diff --git a/.github/workflows/build-and-test-pr.yml
b/.github/workflows/build-and-test-pr.yml
index 017a4b1201..921791f766 100644
--- a/.github/workflows/build-and-test-pr.yml
+++ b/.github/workflows/build-and-test-pr.yml
@@ -207,10 +207,12 @@ jobs:
unit-test:
needs: [check-format, unit-test-prepare]
- name: "Unit Test On ubuntu-latest"
+ name: "Unit Test On ubuntu-latest Java: ${{ matrix.java }}"
runs-on: ubuntu-latest
strategy:
fail-fast: false
+ matrix:
+ java: [ 8, 11, 17, 21 ]
env:
DISABLE_FILE_SYSTEM_TEST: true
CURRENT_ROLE: ${{ matrix.case-role }}
@@ -220,11 +222,11 @@ jobs:
uses: actions/checkout@v4
with:
fetch-depth: 0
- - name: "Set up JDK 21"
+ - name: "Set up JDK ${{ matrix.java }}"
uses: actions/setup-java@v4
with:
distribution: 'zulu'
- java-version: 21
+ java-version: ${{ matrix.java }}
- name: "Set current date as env variable"
run: echo "TODAY=$(date +'%Y%m%d')" >> $GITHUB_ENV
- name: "Cache local maven repository"
@@ -243,8 +245,15 @@ jobs:
key: zookeeper-${{ runner.os }}-${{ env.ZOOKEEPER_VERSION }}
restore-keys: |
zookeeper-${{ runner.os }}-
- - name: "Test with maven"
+ - name: "Test with maven on Java: 8"
+ timeout-minutes: 90
+ if: ${{ matrix.java == '8' }}
+ run: |
+ set -o pipefail
+ ./mvnw ${{ env.MAVEN_ARGS }} clean test verify
-Pjacoco,'!jdk15ge-add-open',skip-spotless -DtrimStackTrace=false
-Dmaven.test.skip=false -Dcheckstyle.skip=false -Dcheckstyle_unix.skip=false
-Drat.skip=false -DembeddedZookeeperPath=${{ github.workspace }}/.tmp/zookeeper
2>&1 | tee >(grep -n -B 1 -A 200 "FAILURE! -- in" > test_errors.log)
+ - name: "Test with maven on Java: ${{ matrix.java }}"
timeout-minutes: 90
+ if: ${{ matrix.java != '8' }}
run: |
set -o pipefail
./mvnw ${{ env.MAVEN_ARGS }} clean test verify
-Pjacoco,jdk15ge-simple,'!jdk15ge-add-open',skip-spotless
-DtrimStackTrace=false -Dmaven.test.skip=false -Dcheckstyle.skip=false
-Dcheckstyle_unix.skip=false -Drat.skip=false -DembeddedZookeeperPath=${{
github.workspace }}/.tmp/zookeeper 2>&1 | tee >(grep -n -B 1 -A 200 "FAILURE!
-- in" > test_errors.log)
@@ -256,13 +265,13 @@ jobs:
with:
token: ${{ secrets.CODECOV_TOKEN }}
verbose: true
- flags: unit-tests
+ flags: unit-tests-java${{ matrix.java }}
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
- name: "Upload surefire reports"
uses: actions/upload-artifact@v4
with:
- name: surefire-reports
+ name: surefire-reports-java${{ matrix.java }}
path: "**/target/surefire-reports/**"
samples-test-prepare:
@@ -293,7 +302,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- java: [ 8, 17 ]
+ java: [ 8, 21 ]
job_id: [1,2,3]
steps:
- uses: actions/checkout@v4
@@ -365,7 +374,7 @@ jobs:
JAVA_VER: ${{matrix.java}}
strategy:
matrix:
- java: [ 8, 17 ]
+ java: [ 8, 21 ]
steps:
- uses: actions/checkout@v4
with:
@@ -408,7 +417,7 @@ jobs:
strategy:
fail-fast: false
matrix:
- java: [ 8, 17 ]
+ java: [ 8, 21 ]
job_id: [1,2,3]
steps:
- uses: actions/checkout@v4
@@ -480,7 +489,7 @@ jobs:
JAVA_VER: ${{matrix.java}}
strategy:
matrix:
- java: [ 8, 17 ]
+ java: [ 8, 21 ]
steps:
- uses: actions/checkout@v4
with:
@@ -501,7 +510,7 @@ jobs:
needs: [check-format, samples-test-result]
strategy:
matrix:
- java: [ 8, 17 ]
+ java: [ 8, 21 ]
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4
@@ -551,7 +560,7 @@ jobs:
needs: [check-format, integration-test-result, samples-test-result]
strategy:
matrix:
- java: [ 8, 17 ]
+ java: [ 8, 21 ]
steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v4