RFR: 8353231: Test com/sun/management/OperatingSystemMXBean/GetProcessCpuLoad still fails intermittently

Kevin Walls kevinw at openjdk.org
Tue Apr 1 10:39:28 UTC 2025


Test com/sun/management/OperatingSystemMXBean/GetProcessCpuLoad still fails intermittently.
On failure, 10 attempts with sleep(200) each time, only read -1 from mbean.getProcessCpuLoad().
The method is documented to return -1 when info is not available, but want to avoid the test accepting a -1 and masking real problems.

Test failures are happening when multiple CPU load reding tests ran on the same host, at the same second.
Add a TEST.properties file containing: exclusiveAccess.dirs=.

-------------

Commit messages:
 - 8353231: Test com/sun/management/OperatingSystemMXBean cpuLoad still fails intermittently

Changes: https://git.openjdk.org/jdk/pull/24352/files
  Webrev: https://webrevs.openjdk.org/?repo=jdk&pr=24352&range=00
  Issue: https://bugs.openjdk.org/browse/JDK-8353231
  Stats: 1 line in 1 file changed: 0 ins; 0 del; 1 mod
  Patch: https://git.openjdk.org/jdk/pull/24352.diff
  Fetch: git fetch https://git.openjdk.org/jdk.git pull/24352/head:pull/24352

PR: https://git.openjdk.org/jdk/pull/24352


More information about the serviceability-dev mailing list