db-derby-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rick Hillegas <rick.hille...@gmail.com>
Subject Re: Derby driver class name v10.15.1.3
Date Wed, 23 Oct 2019 01:33:01 GMT
Thanks for this discussion, Kerry and Jerry. Please file a docs bug and 
suggest how this can be described better.

You are right, it is the modularization of Derby which broke this 
behavior for you. Before modularization, the two drivers (embedded and 
network) lived in the same package but separate jar files (derby.jar and 
derbyclient.jar). That had to be untangled in order to achieve 
jigsaw-ready partitioning of packages across jars.

If you rely on driver autoloading and simply connect via 
DriverManager.getConnection() using a JDBC URL, then the tools jar is 
NOT needed. But if you connect via a DataSource, then you need 
derbytools.jar, which contains the old drivers.

You also need derbytools.jar if you boot the drivers the very 
old-fashioned way via Class.forName(). I believe that the original 
Spring framework pre-dates the driver autoloading introduced by Java 6. 
It seems that you still have to tell Spring the driver class name. Our 
documentation should say more about this old usage pattern. Thanks in 
advance for the doc issue and for your recommendations.


On 10/22/19 2:48 PM, Kerry wrote:
> Thanks Jerry,
> The one artefact I didn't check, but that doesn't seem right somehow now .. seeing as
there is still derbyclient? Should documentation be updated too to reflect that?:
> https://db.apache.org/derby/docs/10.15/getstart/rgslib46043.html
> I can see if I can raise a ticket if that;s the case
> Kerry
> On 22/10/2019 22:24, Jerry Lampi wrote:
>> Kerry,
>> Looks like it moved to derbytools.jar.
>> lib\derbytools.jar->class=org/apache/derby/jdbc/ClientDriver.class
>> Jerry
>> -----Original Message-----
>> From: Kerry <karaf-user@avionicengineers.com>
>> Sent: Tuesday, October 22, 2019 3:56 PM
>> To: derby-user@db.apache.org
>> Subject: Derby driver class name v10.15.1.3
>> Hi,
>> I've been trying to configure a Spring boot application to work with version
of Derby client and I need to specify the driver name in the applications.properties file
(spring.datasource.driver-class-name= *****). Prior to this version I would have used org.apache.derby.jdbc.ClientDriver
in the derbyclient.jar .. but it not longer exists in of Derby? I've looked through
all the other Derby artifacts for this version and cannot find the class.
>> Should I be doing something different with this version of Derby? (because of the
modularisation introduced in Java 9?) I couldn't see anything in the documentation for v10.15.1.3.
>> Thanks
>> Kerry

View raw message