Make StandardExports work with modules and/or IBM JVMs (#281) · diffusiondata/client_java@ce76a49 · GitHub
Skip to content

Commit ce76a49

Browse files
alin-amanabrian-brazil
authored andcommitted
Make StandardExports work with modules and/or IBM JVMs (prometheus#281)
Make StandardExports work in restricted environments or IBM JVMs where com.sun.management.UnixOperatingSystemMXBean is not available. Use reflection instead to collect file descriptor metrics. Use reflection to recursively try invoking a method on the concrete class then on all the interfaces it implements until either success or all attempts have failed
1 parent bd94a66 commit ce76a49

2 files changed

Lines changed: 101 additions & 25 deletions

File tree

simpleclient_hotspot/src/main/java/io/prometheus/client/hotspot/StandardExports.java

Lines changed: 62 additions & 21 deletions

simpleclient_hotspot/src/test/java/io/prometheus/client/hotspot/StandardExportsTest.java

Lines changed: 39 additions & 4 deletions

0 commit comments

Comments
 (0)