Commit d59c1d3
IGNITE-28823 Reduce duration of the "Check java code" GitHub Actions job (commit-check.yml) (#13281)
## [IGNITE-28823](https://issues.apache.org/jira/browse/IGNITE-28823)
The `check-java` job in `commit-check.yml` is the long pole of the "Code
Style, Abandoned Tests, Javadocs" workflow (~8.9 min; every other job in
the workflow finishes in under a minute). It runs three sequential Maven
invocations and has two inefficiencies:
1. The build is single-threaded (no `-T`), although `ubuntu-latest` has
4 vCPUs.
2. The "abandoned tests" step recompiles the whole reactor a second
time. `maven-compiler-plugin` 3.15 logs *"Recompiling the module because
of changed dependency"* for 28 modules (including `ignite-core`, 3322
source files): the second invocation uses a different profile set, so
the plugin's incremental engine treats reactor dependencies as changed
and cascades a full recompile.
### Change
- `-T 1C` on the codestyle / `test-compile` step — parallel reactor
build.
- `-Dmaven.compiler.useIncrementalCompilation=false` on the "abandoned
tests" step — reuse the classes compiled by the previous step instead of
recompiling.
The "abandoned tests" step is intentionally **not** parallelized: the
orphaned-test collection writes to a shared file finalized by the last
reactor module, so `-T` would race.
### Why not merge the two steps
Merging would pull `examples` / `lgpl` modules into the orphaned-test
check (today it runs only over `-Pall-java,scala`) and could newly fail
it. The chosen flag keeps the check scope identical —
profile-conditional source roots (`java-lgpl`) exist only in the
`examples` module, which is not part of the "abandoned tests" reactor.
### Verification (local, full reactor)
| | before | after |
|---|---|---|
| step 2 recompiled modules | 30 (28 "changed dependency") | 2 (0
"changed dependency") |
| step 1 under `-T 1C` | — | 47 modules SUCCESS, checkstyle incl., 0
failures |
The before/after wall-clock is visible on this PR's own CI run, since
the change is to `commit-check.yml` itself.
🤖 Generated with [Claude Code](https://claude.com/claude-code)
---------
Co-authored-by: Claude Opus 4.8 <noreply@anthropic.com>1 parent fb25ec2 commit d59c1d3
1 file changed
Lines changed: 4 additions & 2 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
43 | 43 | | |
44 | 44 | | |
45 | 45 | | |
| 46 | + | |
46 | 47 | | |
47 | 48 | | |
48 | 49 | | |
| |||
96 | 97 | | |
97 | 98 | | |
98 | 99 | | |
99 | | - | |
| 100 | + | |
100 | 101 | | |
101 | 102 | | |
| 103 | + | |
102 | 104 | | |
103 | | - | |
| 105 | + | |
104 | 106 | | |
105 | 107 | | |
106 | 108 | | |
| |||
0 commit comments