Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

HikariCP - no suitable driver error

Tags:

hikaricp

I tried switching to Hikari-CP for java 1.6/1.7 but i m getting the below error:

Caused by: java.sql.SQLException: No suitable driver
    at java.sql.DriverManager.getDriver(DriverManager.java:278) ~[na:1.7.0_45]
    at com.zaxxer.hikari.util.DriverDataSource.<init>(DriverDataSource.java:52) ~[HikariCP-java6-2.3.5.jar:na]
    ... 82 common frames omitted

I m using Oracle DB.

like image 591
Neeraj Avatar asked Dec 14 '22 15:12

Neeraj


1 Answers

This line from documentation was the reason.

When using this property with "old" drivers, you may also need to set the driverClassName property, but try it first without.

The minute i did setup the driverClassName explicitly it started working.

like image 117
Neeraj Avatar answered Feb 12 '23 02:02

Neeraj