Hello,
I am trying to use jmx_exporter as
javaagent and after building the
jar from the latest source code I keep getting the below exception. It was working fine with the older version (I was using the very older version, probably from a year back)
Exception in thread "main" java.lang.reflect.InvocationTargetException
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:62)
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:43)
at java.lang.reflect.Method.invoke(Method.java:498)
at sun.instrument.InstrumentationImpl.loadClassAndStartAgent(InstrumentationImpl.java:386)
at sun.instrument.InstrumentationImpl.loadClassAndCallPremain(InstrumentationImpl.java:401)
Caused by: java.lang.NoSuchFieldError: UNKNOWN
at io.prometheus.jmx.JmxCollector$Rule.<init>(JmxCollector.java:57)
at io.prometheus.jmx.JmxCollector.loadConfig(JmxCollector.java:214)
at io.prometheus.jmx.JmxCollector.<init>(JmxCollector.java:91)
at io.prometheus.jmx.JavaAgent.premain(JavaAgent.java:29)
... 6 more
Please let me know if I a missing something, while building this.