The GitHub Actions job "Coverage" on 
grails-core.git/build/ci-daemon-heap-vs-runner-ram has succeeded.
Run started by GitHub user jamesfredley (triggered by jamesfredley).

Head commit for run:
cc7e0c3353f9b541880438d442a43da149aae81e / James Fredley 
<[email protected]>
build(ci): bound concurrent JVMs on the macOS runner

org.gradle.jvmargs sizes the Gradle daemon only. Test forks are separate
child JVMs that take their heap from maxHeapSize in gradle/test-config.gradle,
so a job's configured heap is the daemon -Xmx plus the concurrent test forks
times the per-fork heap. Those two numbers live in different files and have
never been reasoned about together.

The concurrent fork count is not maxParallelForks. With org.gradle.parallel=true
several Test tasks run at once, so the live JVM count is bounded by Gradle's
global worker pool, which defaults to the CPU count. On the 4-CPU, ~16 GB Linux
and Windows runners that floor is 5G + 4x768m = 8G and fits. On the 3-CPU,
~7 GB macOS runner it is 5G + 3x768m = 7.25G and does not.

Cap --max-workers on the macOS leg, since that is what actually limits
concurrent test and compiler JVMs, and keep maxTestParallel alongside it so no
single task exceeds the same cap. Both are passed through a new runner_arguments
matrix key that is undefined, and therefore empty, for every other entry.

The daemon stays at 5 GB: groovydoc is what needs it, and shrinking it would
trade a memory problem for a slower build. Document the arithmetic next to
org.gradle.jvmargs as a simplified configured-heap floor, explicitly excluding
metaspace, native memory and the forked compiler workers that CompilePlugin
gives their own -Xmx2G, so it is not mistaken for a true peak.

This changes concurrency only. No test is added, removed, skipped or weakened.

Assisted-by: claude-code:claude-opus-5

Report URL: https://github.com/apache/grails-core/actions/runs/32182267446

With regards,
GitHub Actions via GitBox

Reply via email to