public interface ConnectionValidator
setValidator method in either the
ConnectionPool object or the ConnectionPoolManager
in your code (or use the properties file version with the pool manager).
NOTE: The connection passed to the validator is the raw connection from the driver, and has none of the wrapper protection afforded by the pooling mechanism. Implementations should take care to only check the connection's viability, and never make unexpected alterations. Failure to follow this could result in unpredictable pool behaviour.
| Modifier and Type | Method and Description |
|---|---|
boolean |
isValid(Connection con)
Determines whether the specified connection is good to use.
|
boolean isValid(Connection con) throws SQLException
con - Connection instance to check for validitySQLExceptionCopyright © 2013. All Rights Reserved.