|
Henri Yandell made changes - 16/May/06 09:51 AM
Henri Yandell made changes - 16/May/06 11:28 AM
Henri Yandell made changes - 16/May/06 12:16 PM
Henri Yandell made changes - 25/Mar/08 08:11 AM
|
||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||||
but the message can be improved.
How about using the following catch block in the connect method.
} catch(SQLException e) {
throw e;
} catch(NoSuchElementException e) {
throw new SQLNestedException("Cannot get a connection, pool error: " +
e.getMessage(), e);
} catch(RuntimeException e) {
throw e;
} catch(Exception e) {
throw new SQLNestedException("Cannot get a connection, general error: " +
e.getMessage(), e);
}
– Dirk