vibur / vibur-dbcp

Vibur DBCP - concurrent and dynamic JDBC connection pool
http://www.vibur.org
Apache License 2.0
96 stars 11 forks source link

SQL Warnings #1

Closed simeonmalchev closed 9 years ago

simeonmalchev commented 9 years ago

Originally pointed out here:

https://github.com/brettwooldridge/HikariCP/wiki/Pool-Analysis#sql-warnings-2

A connection pool should clear SQL warnings via Connection.clearWarnings() either when the Connection is returned to the pool or before it is taken from the pool. Vibur does not do this.

Further comments:

Determine whether calling Connection.clearWarnings() is necessary, as well as whether it has to happen always or to be configurable.

simeonmalchev commented 9 years ago

Connection.clearWarnings() will be called or not on every connection upon its return to the pool based on an appropriate configuration option. Current thinking is that by default this configuration option will be turned off, as for example Hibernate is always clearing the connection warnings (if any) after using a connection taken from a pool.

simeonmalchev commented 9 years ago

Fixed on Master branch.