+1 on that. John, please make that change.
I have some ugly code being used right now that would have benefited
from that change in my PoolManager subclass.
public Connection getConnection() throws SQLException {
try {
return super.getConnection();
} catch (SQLException e) {
String exceptionMessage = e.getMessage();
if (exceptionMessage.startsWith("Can't obtain connection.
Request timed out.")) {
[...]
}
throw e;
}
On Tue, Jun 23, 2015 at 5:14 PM, John Huss <[email protected]> wrote:
> I'm working on integrating my apps with the latest changes and I noticed
> that in the new connection pool there isn't a special exception thrown when
> the pool is exhausted (too busy). It was handy to be able to identify that
> situation.
>
> It's in UnmanagedPoolingDataSource line 326:
> throw new SQLException("Can't obtain connection. Request to pool timed out.
> Total pool size: " + pool.size());
>
> It used to throw ConnectionUnavailableException
>
> Any chance this can be reintroduced?
>
> John