-
-
Notifications
You must be signed in to change notification settings - Fork 8.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
[🐛 Bug]: Issues when using selenium-remote-driver and opentelemetry sdk #10251
Comments
@valodzka, thank you for creating this issue. We will troubleshoot it as soon as we can. Info for maintainersTriage this issue by using labels.
If information is missing, add a helpful comment and then
If the issue is a question, add the
If the issue is valid but there is no time to troubleshoot it, consider adding the
If the issue requires changes or fixes from an external project (e.g., ChromeDriver, GeckoDriver, W3C),
add the applicable
After troubleshooting the issue, please add the Thank you! |
Issues with agent was resolved in open-telemetry/opentelemetry-java-instrumentation#5169 Issue with preconfigured still remains. This is two line full reproducer that throws error:
|
Thank you for providing the details to help reproduce the problem. I understand the requirement to use OpenTelemetry in your own testing setup.
If you want to instrument Spans and link them to the Selenium spans then the Tracer for the same can be obtained and used as follows: I hope this helps. Apologies if I have missed a use case you are trying to accomplish, in that case, please provide details about it and I can have look again to help figure it out. |
Requirement is to be able configure OpenTelemetry in some advanced way. Based on this https://opentelemetry.io/docs/instrumentation/java/manual_instrumentation/
I suggest remote driver (which is a library) shouldn't configure opentelemetry at all (or at least provide option to disable this behaviour). |
Thank you for providing the feedback. I now understand the situation better. I was working to ensure we can disable tracing when using the RemoteWebDriver as needed. The changes are present in the pull request shared above. |
Thanks for the rapid fix. |
I've just tried v4.1.2, however get the following issue when trying to auto-instrument tests using a RemoteWebDriver.
Should I raise a new bug or should this be reopened? |
that seems to be a different issue, a new bug report would be nice |
Ok, thanks, I'll try to get a smaller repro this afternoon and raise tomorrow. |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
What happened?
Selenium java remote web driver currently initialize OptenTelemetrySdk instance by itself and that makes impossible to use pre configured OpenTelemetry instances (exception thrown).
Also it's impossible to use opentelementry-agent with selenium.
How can we reproduce the issue?
To reproduce issue with agent add "-javaagent:path/to/opentelemetry-javaagent.jar" to project using selenium remote and JPMS.
Relevant log output
Trace when using with java agent:
Selenium version
java 4.1.0
The text was updated successfully, but these errors were encountered: