-
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
Add Libraries doc or section for Java, showing how to set up library instrumentation without an agent #2471
Comments
Hi @svrnm, I would like to contribute on this. I am planning to add a SpringBoot example for this, in case you have any other idea let me know I can explore that option as well. Also would you mind assigning this to me ? |
HEy @nerudadhich, thanks for offering your help! For SpringBoot we have the following in process already: SpringBoot seems to be a "special case" because of the Starter being available, I think in the library page there should be something easier and more clearer of beeing an Instrumentation Library. @open-telemetry/java-approvers any suggestions/comments? |
Hi @svrnm I am planning to add java-http-client end to end working example. Plan:
Let me know if this looks fine to you ? |
Overall that sounds good to me, there are a few adjustments I would like to make. Ultimately this should be the content of Using instrumentation libraries, which is very basic right now. At the end it should have more similarity with the one you can see for JavaScript So, here is my proposal how it should look like: Begin the page with the following:
The "real" work is the "Use Instrumentation Libraries" section:
|
Thanks @svrnm this sounds good to me. Will work and raise a PR. |
nice :-) |
Also @tylerbenson don't feel ashamed to copy-paste from the JS docs or something else and just tweak! Especially for the commentary between code samples, more uniformity (if it makes sense) is generally good. |
What do you have in mind? Is it for the following reasons or others? https://opentelemetry.io/docs/languages/java/automatic/spring-boot/ |
Those are good reasons, yes, although I think there's a few more:
|
You probably mean the Java agent overhead after the application startup. In this case, the user could try to turn off some Java agent instrumentations. |
Nope, in this case what we observed had nothing to do with startup. The only way forward was to explicitly turn on just a few instrumentations in-app and focus on manual instrumentation. |
There's scenarios where you may not want to/cannot use the java agent for autoinstrumentation, but do want to get library instrumentation. This should be documented with code samples, similar to the .NET page: https://opentelemetry.io/docs/instrumentation/net/libraries/
The text was updated successfully, but these errors were encountered: