Skip to content
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

Outdated auto-annotations library doesn't work with v1.0.x #3091

Closed
topher1120 opened this issue Apr 1, 2021 · 5 comments
Closed

Outdated auto-annotations library doesn't work with v1.0.x #3091

topher1120 opened this issue Apr 1, 2021 · 5 comments
Labels
Bug Something isn't working

Comments

@topher1120
Copy link
Contributor

Attempting to use the @WithSpan annotation in the library "opentelemetry-extension-auto-annotations" v 0.10.0 (the latest release on maven.org) with "opentelemetry-api" v1.0.1 (and presumably 1.0.0) causes a runtime ClassNotFoundException.
Specifically, the message is "java.lang.ClassNotFoundException: io.opentelemetry.api.trace.Span$Kind". Looking at the source on GitHub, this has been fixed in main, but has not been released.

Can a new version of opentelemetry-extension-auto-annotations be released to resolve this?

Steps to reproduce
Create a project with the OpenTelemetry Java Agent v1.0.1. Add opentelemetry-extension-auto-annotations v0.10.0 (I also added opentelemetry-api v1.0.1) to the project. Add a @WithSpan annotation to a method in a class. Compile will work, but error will happen during runtime.
I'm using a Spring application, so it happens during startup on a controller.

What did you expect to see?
I expected no exceptions and that spans would be created and exported.

What did you see instead?
ClassNotFoundException when the annotation was loaded.

What version and what artifacts are you using?
Artifacts: opentelemetry-api v1.0.1, opentelemetry-javaagent v1.0.1, opentelemetry-extension-auto-annotations v0.10.0

Environment
Compiler: Zulu v11.0.10
OS: XUbuntu 20.04

@topher1120 topher1120 added the Bug Something isn't working label Apr 1, 2021
@jkwatson
Copy link
Contributor

jkwatson commented Apr 1, 2021

that module was renamed to opentelemetry-extension-annotations and should work fine with the appropriate versions.

@jkwatson
Copy link
Contributor

jkwatson commented Apr 1, 2021

for the latest list of non-alpha versions and modules, I recommend taking a look at the contents of the bom:

https://search.maven.org/artifact/io.opentelemetry/opentelemetry-bom/1.0.1/pom

@topher1120
Copy link
Contributor Author

Thank you, I'll take a look at that tomorrow. Documentation at https://opentelemetry.io/docs/java/automatic_instrumentation/#configure-withspan-annotation appears to be out of date with the release. If no one else updates, I may have time to submit a PR this weekend.

@jkwatson
Copy link
Contributor

jkwatson commented Apr 2, 2021

Thank you, I'll take a look at that tomorrow. Documentation at https://opentelemetry.io/docs/java/automatic_instrumentation/#configure-withspan-annotation appears to be out of date with the release. If no one else updates, I may have time to submit a PR this weekend.

we're working on getting the docs fixed as well. #3081

@jkwatson
Copy link
Contributor

jkwatson commented Apr 2, 2021

closing this as not-a-bug-but-a-failing-of-maven-central-search

@jkwatson jkwatson closed this as completed Apr 2, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants