Looks like there is a bug in prepared statement pooling of DriverAdapterCPDS. You can report this issue in bugzilla against v1.1.
Sort term solution: Disable the statement pooling, cpds.setPoolPreparedStatements(false) or switch to BasicDataSource (statement pooling included in v1.1)
But this bug should be fixed of couse.
Regards Dirk
Dave Oxley wrote:
When setting up my pool like this: DriverAdapterCPDS cpds = new DriverAdapterCPDS();
cpds.setDriver(jdbc_driver_name); cpds.setUrl(url); cpds.setUser(user); cpds.setPassword(pwd); cpds.setPoolPreparedStatements(true);
SharedPoolDataSource tds = new SharedPoolDataSource(); tds.setConnectionPoolDataSource(cpds); tds.setMaxActive(50); tds.setMaxWait(-1); tds.setMaxIdle(10); tds.setDefaultAutoCommit(false);
I get the following exception when calling prepareStatement(sql):
Caused by: java.lang.RuntimeException: java.lang.ClassCastException
at org.apache.commons.dbcp.cpdsadapter.PooledConnectionImpl.makeObject(PooledConnectionImpl.java:324)
at org.apache.commons.pool.impl.GenericKeyedObjectPool.borrowObject(GenericKeyedObjectPool.java:792)
at org.apache.commons.dbcp.cpdsadapter.PooledConnectionImpl.prepareStatement(PooledConnectionImpl.java:243)
at org.apache.commons.dbcp.cpdsadapter.ConnectionImpl.prepareStatement(ConnectionImpl.java:332)
Dave.
--------------------------------------------------------------------- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED]