Closed ato closed 8 years ago
@ato, thanks for reporting this.
Most likely is a regression as you suggested. Will try to fix it and push a new release out as soon as I can. In the mean time, the workaround that you suggested is completely viable, yes.
This is now fixed on master. Will try to push out a new release to maven central sometime tomorrow.
Awesome. Thanks! :-)
Just pushed version 8.0 to maven central. Should be available there soon.
/cc @dcalde
StatementInvocationHandler intercepts the close() method and unless the statement cache is enabled it appears to never close the wrapped statement object:
https://github.com/vibur/vibur-dbcp/blob/a893a63/src/main/java/org/vibur/dbcp/proxy/StatementInvocationHandler.java#L93
Could this be a regression introduced by the refactoring in commit e5e4116f8cbdb548a86507ef00b0e9734dbb09ef? Prior to that commit there was an else branch in processClose():
I ran into this when debugging an OutOfMemoryError with the Oracle JDBC driver (which internally holds onto a list of all open statements). Enabling statement cache with setStatementCacheMaxSize seems to be a viable workaround as the statement cache will close the wrapped statement on eviction.