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

Fix integration with jersey-client 2.30 #2071

Merged
merged 3 commits into from
Jan 19, 2021

Conversation

laurit
Copy link
Contributor

@laurit laurit commented Jan 18, 2021

Fixes #2031
We can't use WrappedFuture on jersey-client 2.30 as jersey-client attempts to cast it to CompletableFuture.

@laurit laurit changed the title Fix integration with jetty-client 2.30 Fix integration with jersey-client 2.30 Jan 18, 2021
return future;
}

public static void handleException(ClientRequest context, Throwable exception) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

We generally add instrumentation-specific handling to the *Tracer classes themselves instead of separating utils, would that work here?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Tracer class is in a different module jaxrs-client-2.0-common adding these methods there would also require moving WrappedFuture there. Adding a tracer to jaxrs-client-2.0-jersey-2.0 also doesn't seem like a good option because this module doesn't really have any specialised tracing code.

Copy link
Member

@trask trask left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks! One suggestion below, in addition to @anuraaga's suggestion.

…-common/javaagent/jaxrs-client-2.0-common-javaagent.gradle

Co-authored-by: Trask Stalnaker <trask.stalnaker@gmail.com>
@iNikem iNikem merged commit cdfe8e0 into open-telemetry:master Jan 19, 2021
@laurit laurit deleted the jersey-client-completable-future branch February 4, 2021 20:54
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.

jaxrs-client instrumentation causes failure in JerseyInvocation due to CompletableFuture cast
5 participants