-
Notifications
You must be signed in to change notification settings - Fork 1.2k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
java.rmi.UnmarshalException while scraping metrics #695
Comments
Please let me know how exactly you start your application and how you use the javaagent and the collector dependency. |
I defined the dependencies in pom.xml:
then the application is started like that: we also tried using the javaagent directly in our weblogic process like it is described here: https://github.com/prometheus/jmx_exporter With the new version the method |
You write
So I suggest you use it like this, instead of trying to use it as a dependencies in your application. |
Hello, sorry but there was a misunderstanding. In out project we don't use javaagent, Angela added in the pox.xml just for test. The pom.xml is: <prometheus.jmx.version>0.16.1</prometheus.jmx.version>
<dependency>
<groupId>io.prometheus.jmx</groupId>
<artifactId>collector</artifactId>
<version>${prometheus.jmx.version}</version>
</dependency> And we want to use the jmx exporter like a independent HTTP server , not a java agent. So with the new version, like Angela wrote, we have this UnmarshalException :
Is it possible to fix this problem? Regards |
@fstab yes antonella is right. this was a wrong config i sent you. we do not use this dependency in our pom.xml . is this an issue you could fix? |
Hi, there is no need to implement your own standalone HTTP server. You can download
An example config looks like this (replace hostPort: localhost:7072
rules:
- pattern: ".*" |
Hello @fstab So i tried to override the JMXScraper class from the io.prometheus.jmx.collector library. I used the old mechanism to load the attributes of a Bean step by step instead of loading a whole list. So the problem is, that with the new version of the library 0.16.1 a whole list of attributes of a Mbean is loaded. And if one of these attributes is of a type which is unknown or not a primitive type (in my case a Here you see all attributes and two of them are Weblogic-specific classes, for example weblogic.management.runtime.ExecuteThreads: So with the new mechanism of loading i will not get any values of these attributes at all. Angela |
hello all
we upgraded the jmx-exporter and collector in our application to a newer version:
jmx_prometheus_javaagent
from 0.11.0 to 0.16.1the goal of our application is to scrape metric of different servers (tomcat, weblogic). it's a standalone app and we do not use any tomcat or weblogic dependencies .
now we are facing some issues while scraping bean metrics. if we use the old dependency, we are able to get the thread metrics from our weblogic server like:
With the new dependencies we get an error:
btw: if i use jconsole i sucessfully retrieve the metrics
Any help is very appreciated!
Regards Angela
The text was updated successfully, but these errors were encountered: