From 75007c82bcb2a3afc22ec4928867dea4305d5c7c Mon Sep 17 00:00:00 2001 From: JackieTien97 Date: Sun, 17 May 2026 16:04:28 +0800 Subject: [PATCH 1/2] Speed up Codecov CI by running surefire with 2 parallel forks The codecov job currently runs ~66 min, ~51 min of which is the DataNode unit tests on a single JVM at a time. The datanode pom sets reuseForks=false (fresh JVM per test class) and surefire defaults to forkCount=1, so on the 4-core runner only one test class runs at any moment. The parent pom already configures per-fork working directories (fork_${surefire.forkNumber}), so the project is plumbed for parallel forks but never enables them. Pass -DforkCount=2 to the codecov maven invocation so two test JVMs run in parallel, cutting the DataNode UT phase roughly in half without changing test isolation semantics. --- .github/workflows/sonar-codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-codecov.yml b/.github/workflows/sonar-codecov.yml index adb943a7f62e7..f81885c5d6390 100644 --- a/.github/workflows/sonar-codecov.yml +++ b/.github/workflows/sonar-codecov.yml @@ -50,7 +50,7 @@ jobs: restore-keys: ${{ runner.os }}-m2- - name: Test run: | - mvn -B -P with-code-coverage clean package -pl distribution,iotdb-client/cli,iotdb-client/session,iotdb-client/jdbc -am -Dtest.port.closed=true + mvn -B -P with-code-coverage clean package -pl distribution,iotdb-client/cli,iotdb-client/session,iotdb-client/jdbc -am -Dtest.port.closed=true -DforkCount=2 mvn -B -P with-code-coverage post-integration-test -pl code-coverage - name: Upload coverage reports to codecov uses: codecov/codecov-action@v5 From 3ffdfc0da8bc45e300ce288ca1cff7e1f9a2151a Mon Sep 17 00:00:00 2001 From: JackieTien97 Date: Sun, 17 May 2026 16:59:38 +0800 Subject: [PATCH 2/2] Bump codecov surefire forkCount from 2 to 4 --- .github/workflows/sonar-codecov.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.github/workflows/sonar-codecov.yml b/.github/workflows/sonar-codecov.yml index f81885c5d6390..4f62c8926fbe0 100644 --- a/.github/workflows/sonar-codecov.yml +++ b/.github/workflows/sonar-codecov.yml @@ -50,7 +50,7 @@ jobs: restore-keys: ${{ runner.os }}-m2- - name: Test run: | - mvn -B -P with-code-coverage clean package -pl distribution,iotdb-client/cli,iotdb-client/session,iotdb-client/jdbc -am -Dtest.port.closed=true -DforkCount=2 + mvn -B -P with-code-coverage clean package -pl distribution,iotdb-client/cli,iotdb-client/session,iotdb-client/jdbc -am -Dtest.port.closed=true -DforkCount=4 mvn -B -P with-code-coverage post-integration-test -pl code-coverage - name: Upload coverage reports to codecov uses: codecov/codecov-action@v5