Atomikos Forum |
|
After database crash AtomikosDataSourceBean pool does not return new connection. It does not work on Linux but it works on Windows :( I got following exeption:
java.lang.reflect.UndeclaredThrowableException at $Proxy74.close(Unknown Source) at com.atomikos.jdbc.AtomikosXAPooledConnection.destroy(AtomikosXAPooledConnection.java:60) at com.atomikos.datasource.pool.ConnectionPool.borrowConnection(ConnectionPool.java:141) at com.atomikos.jdbc.AbstractDataSourceBean.getConnection(AbstractDataSourceBean.java:289) at com.atomikos.jdbc.AbstractDataSourceBean.getConnection(AbstractDataSourceBean.java:341) at pl.carrierex.common.dbaccess.DbConnection.getConnection(DbConnection.java:81) at pl.carrierex.common.dbaccess.Db.getConnection(Db.java:38) at pl.carrierex.common.dbaccess.Db.<init>(Db.java:31) ... and Caused by: java.lang.reflect.InvocationTargetException at sun.reflect.GeneratedMethodAccessor63.invoke(Unknown Source) at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) at java.lang.reflect.Method.invoke(Method.java:597) at org.postgresql.xa.PGXAConnection$ConnectionHandler.invoke(PGXAConnection.java:146) ... 50 more Caused by: org.postgresql.util.PSQLException: This connection has been closed. at org.postgresql.jdbc2.AbstractJdbc2Connection.checkClosed(AbstractJdbc2Connection.java:714) at org.postgresql.jdbc2.AbstractJdbc2Connection.clearWarnings(AbstractJdbc2Connection.java:597) at org.postgresql.ds.jdbc23.AbstractJdbc23PooledConnection$ConnectionHandler.invoke(AbstractJdbc23PooledConnection.java:319) at $Proxy74.close(Unknown Source) ... 54 more
I also suspect that is bug. In windows exception looks like:
WARNING: atomikos connection pool 'CRMDs': error creating proxy of connection an AtomikosXAPooledConnection with a SessionHandleState with 0 context(s) com.atomikos.datasource.pool.CreateConnectionException: Error executing testQuery at com.atomikos.jdbc.AtomikosXAPooledConnection.testUnderlyingConnection(AtomikosXAPooledConnection.java:100) at com.atomikos.datasource.pool.AbstractXPooledConnection.createConnectionProxy(AbstractXPooledConnection.java:43) at com.atomikos.datasource.pool.ConnectionPool.borrowConnection(ConnectionPool.java:135) and it has name CreateConnectionException instead UndeclaredThrowableException |