Generalizes the Bazel-server JVM heap sizing introduced in #58821 (SERVER-131207) so it applies to *all* Evergreen Bazel jobs by default, rather than only the large resmoke test task group.
-
-
- What changed
-
- *`evergreen/generate_evergreen_bazelrc.sh`*: `bazel_jvm_heap_ram_ratio` now defaults to `0.5` (`${bazel_jvm_heap_ram_ratio:-0.5}`) instead of being a no-op when unset. Since this script runs as part of the shared `setup bazel (credentials, bazelrc)` func, the `startup --host_jvm_args=-Xmx<ratio*RAM>m` line is now emitted for every Evergreen Bazel job.
- *`etc/evergreen_yml_components/tasks/resmoke/non_server_teams/tasks.yml`*: removed the now-redundant per-task `bazel_jvm_heap_ram_ratio: "0.5"` override, since the default covers it.
-
-
- Why
The Bazel server JVM otherwise defaults to ~25% of host RAM. On jobs that hold many concurrent remotely-executed actions in memory that heap gets exhausted, sending the server into a GC death-spiral (heap pinned ~99% full, all worker threads parked, build stalls) — which is what a `run_bazel_compiledb` JVM thread dump showed. Bumping the ceiling to 50% of host RAM gives the server headroom across the board.
- Why
-
-
-
- Safety
-
- *Linux-only*: guarded by `[[ -r /proc/meminfo ]]`, so Windows/macOS jobs are unaffected.
- *Ceiling, not reservation*: `-Xmx` is a max; G1 only grows to it under real pressure.
- *Overridable*: tasks needing a different ratio can still set the `bazel_jvm_heap_ram_ratio` expansion.
- is related to
-
SERVER-131207 Improve resmoke_test parallelism in large bazel test invocations
-
- Closed
-
- related to
-
SERVER-132031 Symbol checker task fails in commit-queue due to missing deps in BUILD.bazel files
-
- In Code Review
-