eclipse-openj9 / openj9

Eclipse OpenJ9: A Java Virtual Machine for OpenJDK that's optimized for small footprint, fast start-up, and high throughput. Builds on Eclipse OMR (https://github.com/eclipse/omr) and combines with the Extensions for OpenJDK for OpenJ9 repo.
Other
3.28k stars 722 forks source link

functionality tests fail to compile on jdk21+ #19127

Open pshipton opened 8 months ago

pshipton commented 8 months ago

Due to https://github.com/eclipse-openj9/openj9/pull/18532

getTotalPhysicalMemory() was deprecated and removed in jdk19, replaced by getTotalMemorySize() from jdk14.

https://openj9-jenkins.osuosl.org/job/Test_openjdk22_j9_sanity.functional_aarch64_linux_Nightly_testList_0/28

23:24:13      [javac] /home/jenkins/workspace/Test_openjdk22_j9_sanity.functional_aarch64_linux_Nightly_testList_0/aqa-tests/functional/cmdLineTests/criu/src/org/openj9/criu/SoftmxTest.java:83: error: cannot find symbol
23:24:13      [javac]           long memorySize = ((com.ibm.lang.management.OperatingSystemMXBean) ManagementFactory.getOperatingSystemMXBean()).getTotalPhysicalMemory();
23:24:13      [javac]                                                                                                                           ^
23:24:13      [javac]   symbol:   method getTotalPhysicalMemory()
23:24:13      [javac]   location: interface OperatingSystemMXBean
pshipton commented 8 months ago

@amicic fyi

amicic commented 8 months ago

feel free to revert

pshipton commented 8 months ago

feel free to revert

Done