commons-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From David Durham <david.durham...@gmail.com>
Subject Pooling Datasource that implements LoginTimeout
Date Thu, 13 Oct 2005 20:48:33 GMT
BasicDatasource hangs for the full TCP timeout when testing a
PoolableConnectionFactory:

    private static void
validateConnectionFactory(PoolableConnectionFactory connectionFactory)
throws Exception {

        Connection conn = null;

        try {

            conn = (Connection) connectionFactory.makeObject();

            connectionFactory.activateObject(conn);

            connectionFactory.validateConnection(conn);

            connectionFactory.passivateObject(conn);

        }

        finally {

            connectionFactory.destroyObject(conn);

        }

    }


Is there one there a datasource which implements the login timeout
available, or can anyone give a brief description of how to accomplish
it?


-Dave

---------------------------------------------------------------------
To unsubscribe, e-mail: commons-user-unsubscribe@jakarta.apache.org
For additional commands, e-mail: commons-user-help@jakarta.apache.org


Mime
View raw message