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

Quarkus 2.0.1.Final fails when using opentracing-jdbc (oracle DB) #18509

Closed
enbohm opened this issue Jul 8, 2021 · 4 comments
Closed

Quarkus 2.0.1.Final fails when using opentracing-jdbc (oracle DB) #18509

enbohm opened this issue Jul 8, 2021 · 4 comments
Labels

Comments

@enbohm
Copy link

enbohm commented Jul 8, 2021

Describe the bug

Using Quarkus 2.0.1.Final with opentracing-jdbc results in exception when trying to execute any DB statements towards an Oracle DB. Downgrading to 2.0.0.Final everything is working.

Expected behavior

Using opentracing-jdbc should not result in any exception.

Actual behavior

Exception is thrown with the following stacktrace when trying to execute any DB-statements:

SRHCK01000: Error processing Health Checks: java.lang.NoClassDefFoundError: Could not initialize class oracle.net.nt.Clock
at oracle.net.nt.NetStatImpl.incrementBytesSent(NetStatImpl.java:80)
at oracle.net.nt.TimeoutSocketChannel.write(TimeoutSocketChannel.java:468)
at oracle.net.ns.NIOPacket.writeToSocketChannel(NIOPacket.java:361)
at oracle.net.ns.NIOConnectPacket.writeToSocketChannel(NIOConnectPacket.java:255)
at oracle.net.ns.NSProtocolNIO.negotiateConnection(NSProtocolNIO.java:157)
at oracle.net.ns.NSProtocol.connect(NSProtocol.java:350)
at oracle.jdbc.driver.T4CConnection.connect(T4CConnection.java:1967)
at oracle.jdbc.driver.T4CConnection.logon(T4CConnection.java:640)
at oracle.jdbc.driver.PhysicalConnection.connect(PhysicalConnection.java:1032)
at oracle.jdbc.driver.T4CDriverExtension.getConnection(T4CDriverExtension.java:90)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:681)
at oracle.jdbc.driver.OracleDriver.connect(OracleDriver.java:602)
at io.agroal.pool.ConnectionFactory.createConnection(ConnectionFactory.java:204)
at io.agroal.pool.ConnectionPool$CreateConnectionTask.call(ConnectionPool.java:490)
at io.agroal.pool.ConnectionPool$CreateConnectionTask.call(ConnectionPool.java:472)
at java.base/java.util.concurrent.FutureTask.run(FutureTask.java:264)
at io.agroal.pool.util.PriorityScheduledExecutor.beforeExecute(PriorityScheduledExecutor.java:68)
at java.base/java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1126)
at java.base/java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:628)
at java.base/java.lang.Thread.run(Thread.java:834)

To Reproduce

See https://github.com/enbohm/jdbc-tracing-2-0-1

Configuration

quarkus.datasource.db-kind=oracle
quarkus.datasource.username=system
quarkus.datasource.password=oracle
quarkus.datasource.jdbc.url=jdbc:oracle:thin:@127.0.0.1:49161

Screenshots

(If applicable, add screenshots to help explain your problem.)

Environment (please complete the following information):

Output of uname -a or ver

Darwin MacBook-Pro.local 20.5.0 Darwin Kernel Version 20.5.0: Sat May 8 05:10:33 PDT 2021; root:xnu-7195.121.3~9/RELEASE_X86_64 x86_64

Output of java -version

openjdk version "11" 2018-09-25
OpenJDK Runtime Environment 18.9 (build 11+28)
OpenJDK 64-Bit Server VM 18.9 (build 11+28, mixed mode)

Quarkus version or git rev

2.0.1.Final

Build tool (ie. output of mvnw --version or gradlew --version)

Maven home: /usr/local
Java version: 11, vendor: Oracle Corporation, runtime: /Library/Java/JavaVirtualMachines/jdk-11.jdk/Contents/Home
Default locale: sv_SE, platform encoding: UTF-8
OS name: "mac os x", version: "10.16", arch: "x86_64", family: "mac"

Additional context

Downgrading to Quarkus 2.0.0.Final seems to solve the problem

@enbohm enbohm added the kind/bug Something isn't working label Jul 8, 2021
@quarkus-bot
Copy link

quarkus-bot bot commented Jul 8, 2021

/cc @Ladicek, @kenfinnigan

@enbohm
Copy link
Author

enbohm commented Jul 9, 2021

Upgrading the opentracing-jdbc by explicit set the latest version seems to solve the issue (at least in JVM mode).

<dependency>
      <groupId>io.opentracing.contrib</groupId>
      <artifactId>opentracing-jdbc</artifactId>
      <version>0.2.15</version>
</dependency>

Looks like Quarks 2.0.0.Final was using 0.2.12 and Quarkus 2.0.1.Final using an older version 0.2.4. Probably related to #18033

@loicmathieu
Copy link
Contributor

@enbohm this is annoying, we had to dowgrade to 0.2.4 for native support, but you need version 0.2.15.
I'm surprised by the fact that the stacktrace didn't show any opentracing frames.

@gsmet
Copy link
Member

gsmet commented Dec 20, 2021

This is a bit in conflict with #18033 . We will need to find a solution to upgrade OpenTracing JDBC at some point. Let's get all the information in #18033 .

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants