Is There any Java agent to monitor the metrices of all JVM running processes in my POD?

Viewed 95

I am looking for a java agent to monitor the metrics of all JVM running processes in my POD. I want to collect the metrics for each process like CPU, Memory and forward them to stdout or Splunk. How Can I achieve that?

1 Answers

There are a bunch of ways to do this, but I'll highlight 3 of them.

  1. Jolokia - Jolokia is remote JMX with JSON over HTTP. You essentially enable this in your java arguments and it will spin up a server that allows you to request json. You can also install hawtio online for a gui in kubernetes. If you go to Red Hat, the JBoss image has Jolokia installed by defaults. That's how it does it's health checks.
  2. Prometheus - The Prometheus agent can also be installed. You can also ask for metrics on an http/https port just like jolokia.
  3. OpenTelemetry - Opentelemetry is newer and I honestly haven't played around with it yet.

If you run Red Hat JBoss images , both Prometheus and Jolokia extensions are added by default. Hope this helps, Jay

Related