Skip to content

Conversation

@adamw
Copy link

@adamw adamw commented Sep 20, 2024

I'd like to propose adding a set of rules for reporting basic JVM metrics (GC, memory, classloaders). I've seen some of these mentioned in the README, though there's no built-in ruleset.

I've created my own basing on another otel project, and maybe this might be useful for others as well? (probably in combination with the rule sets already defined (for tomcat, kafka etc.)). Initially, I kind of expected these to be reported by default, but it turned out otherwise :) Unless there are other mechanisms for funnelling the basic JVM metrics into otel, that are preferable?

@adamw adamw requested a review from a team as a code owner September 20, 2024 19:55
@linux-foundation-easycla
Copy link

linux-foundation-easycla bot commented Sep 20, 2024

CLA Signed


The committers listed above are authorized under a signed CLA.

@trask
Copy link
Member

trask commented Sep 23, 2024

hi @adamw!

I kind of expected these to be reported by default

you should be getting these by default: https://github.com/open-telemetry/semantic-conventions/blob/main/docs/runtime/jvm-metrics.md

@adamw
Copy link
Author

adamw commented Sep 24, 2024

@trask Thanks! Do you mean these metrics should be gathered & exposed automatically - just by using the SDK (I don't think that's happening ;) )? Or that I should rename the metrics I added here to adhere to this naming convention (which I should, if they are not gathered automatically)?

@adamw
Copy link
Author

adamw commented Sep 24, 2024

(btw. - I'm not using the Java agent, but trying to initialize everything from my main method, fwiw)

@laurit
Copy link
Contributor

laurit commented Sep 24, 2024

Do you mean these metrics should be gathered & exposed automatically - just by using the SDK (I don't think that's happening ;) )?

Just using the SDK is not enough to get these, you'll need https://github.com/open-telemetry/opentelemetry-java-instrumentation/tree/main/instrumentation/runtime-telemetry/runtime-telemetry-java8/library

@adamw
Copy link
Author

adamw commented Sep 24, 2024

@laurit Works great, I missed that library, thank you! Closing this then :)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants