src/main/java/org/vibur/dbcp/pool/PoolOperations.java
private void processSQLExceptions(ConnHolder connHolder, SQLException[] exceptions) {
        int connVersion = connHolder.version();
        SQLException criticalException = getCriticalSQLException(exceptions);
        if (criticalException != null && connectionFactory.compareAndSetVersion(connVersion, connVersion + 1)) {
            int destroyed = poolService.drainCreated(); // destroys all connections in the pool
            logger.error("Critical SQLState {} occurred, destroyed {} connections from pool {}, current connection version is {}.",
                    criticalException.getSQLState(), destroyed, getPoolName(dataSource), connectionFactory.version(), criticalException);
        }
    }
private void processSQLExceptions(ConnHolder connHolder, SQLException[] exceptions) {
        int connVersion = connHolder.version();
        SQLException criticalException = getCriticalSQLException(exceptions);
        if (criticalException != null && connectionFactory.compareAndSetVersion(connVersion, connVersion + 1)) {
            int destroyed = poolService.drainCreated(); // destroys all connections in the pool
            logger.error("Critical SQLState {} occurred, destroyed {} connections from pool {}, current connection version is {}.",
                    criticalException.getSQLState(), destroyed, getPoolName(dataSource), connectionFactory.version(), criticalException);
        }
    }
private void processSQLExceptions ( ConnHolder connHolder , SQLException [ ] exceptions ) { int connVersion = connHolder . version ( ) ; SQLException criticalException = getCriticalSQLException ( exceptions ) ; if ( criticalException != null && connectionFactory . compareAndSetVersion ( connVersion , connVersion + 1 ) ) { int destroyed = poolService . drainCreated ( ) ; // destroys all connections in the pool logger . error ( "Critical SQLState {} occurred, destroyed {} connections from pool {}, current connection version is {}." , criticalException . getSQLState ( ) , destroyed , getPoolName ( dataSource ) , connectionFactory . version ( ) , criticalException ) ; } }
Processes SQL exceptions that have occurred on the given JDBC Connection (wrapped in a {@code ConnHolder}).

@param connHolder the given connection
@param exceptions the list of SQL exceptions that have occurred on the connection; might be an empty list but not a {@code null}
Processes SQL exceptions that have occurred on the given JDBC Connection ( wrapped in a { @code ConnHolder } ) .