Potential issue with DriverManager#isDriverAllowed causing LinkageError
Feng Shen
shenfeng197 at gmail.com
Thu Aug 28 09:37:36 UTC 2025
Hello,
I encountered a potential issue related to
java.sql.DriverManager#isDriverAllowed.
In my project, I use multiple custom class loaders derived from the system
class loader. They are isolated from each other. One of my class loaders
(let’s call it A) is complete, while another class loader (say B) only has
a JDBC driver class in its resource directory, but lacks some of its
dependencies.
When DriverManager#isDriverAllowed checks the driver, this situation can
lead to a LinkageError, which in turn prevents obtaining a database
connection.
I think this behavior could potentially be optimized. If the community
agrees, I’d be happy to submit a PR to address this issue.
Thanks,
shenfeng
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://mail.openjdk.org/pipermail/core-libs-dev/attachments/20250828/045f3e33/attachment-0001.htm>
More information about the core-libs-dev
mailing list