I'm trying to set up a connection pool using com.microsoft.sqlserver.jdbc.SQLServerXADataSource
in Tomcat8. While everything is fine using com.microsoft.sqlserver.jdbc.SQLServerDriver
, when using SQLServerXADataSource
, Tomcat claims No suitable driver found
.
I'm sure that the correct driver jar is in $CATALINA\lib
, however I am not sure if it is loaded correctly, as com.microsoft.sqlserver.jdbc.SQLServerDriver
is working with and without that driver in lib
. Maybe there is some other driver loaded which I could not locate.
Similar problem on Windows and OS X so far...
Does anyone know how to solve this?
UPDATE: Im setting up my datasource in-Code, like this:
//Class.forName("com.microsoft.sqlserver.jdbc.SQLServerXADataSource");
Class.forName("com.microsoft.sqlserver.jdbc.SQLServerDriver");
final ConnectionFactory connectionFactory = new DriverManagerConnectionFactory(connectURI, null);
final PoolableConnectionFactory poolableConnectionFactory = new PoolableConnectionFactory(connectionFactory, null);
final GenericObjectPool<PoolableConnection> connectionPool = new GenericObjectPool<>(poolableConnectionFactory);
poolableConnectionFactory.setPool(connectionPool);
return new PoolingDataSource<>(connectionPool);