Changes to Proxool
... Logo
The latest version of Proxool is 0.9.1
You can donate to Proxool in the usual way:
0.9.1 - 23 August 2008
- Fixed bundling of Cglib in binary release. Cglib is "repackaged" using JarJar. This release just adds the file proxool-cglib.jar to the binary release.
0.9.0 - 19 August 2008
- Changed the warning message when a statement is closed which isn't known to be open. This can happen if you close a statement twice and the message now suggests that as a cause.
- Changed the signature of the ConnectionListenerIF.onDeath() method to include a reasonCode defining exactly why the connection is about to die. This gives you the chance to decide whether to commit or rollback. See the onDeath() method for a list of possible codes.
- New naming policy for Cglib stops conflicts with other Cglib instances that are running (even ones in different packages). Without using our own naming policy we end up with exceptions like:
            java.lang.LinkageError: duplicate class definition:
- Added ProxoolFacade.disableShutdownHook so that you can choose to explicitly shutdown Proxool programatically. This is useful because the order that the JVM calls shutdown hooks isn't easily controlled and you might want to shutdown Proxool *after* you've done some cleaning up yourself. Suggested by Alex Lemaire.
- Fixed bug in ProxoolDataSource to add in maximum-active-time. Credit to Paolo Di Tommaso.
- Fixed bug in AdminServlet where select HTML tag was not closed properly. Credit to Paolo Di Tommaso.
- The Statement.getConnection() method now returns the wrapped connection rather than the delegate, aloowing you to close() it safely.
- Repackaged Cglib 2.1_3 (including its own repackaged version of ASM). Cglib is now repackaged using JarJar (see the repackage-cglib Ant target in the source distribution). One of the goals of this upgrade is to get Proxool to work with JDK 1.6 - more testing is needed before we can know the status of that. (Note that you can't build Proxool from source with 1.6 yet because if unimplemented methods in DataSource).
- You can now configure the DataSource with delegate properties. Use the delegateProperties property.
0.9.0RC1 - 2 March 2006
- All connections are now wrapped in disposable wrappers. This means that once you have closed a connection (thereby returning it to the pool) you can no longer do anything to it that might influence its behaviour for the next client that picks it up.
- Connections, Statements, PreparedStatements, and CallableStatements now implement all the public intefaces that the delegate connection does. This means that you can, for instance, cast a Connection directly to the driver specific one. Or more precisely, any of the interfaces that the driver object implements. You can only cast your exception into an interface - concrete classes aren't supported at this time.
- You can now inject interfaces for proxied objects that expose public methods that aren't declared in an interface. So if your vendor Connection, Statement, PreparedStatement or CallableStatement have any public methods that aren't declared in an interface (and therefore not exposed automatically) you can just write your own interface that declares the same signature. Even though the vendor object doesn't implement your interface directly, the proxied object will behave as if it does.
- ProxoolFacade now has killConnection that accepts the Connection object itself, so you don't have to know the pool alias and connection ID.
- ProxoolFacade now has getId() which will give you the ID for any connection.
- ProxoolFacade now has getAlias() which will give you the pool alias for any connection.
- ProxoolFacade now has a no-parameter overloaded version of shutdown() for ease of integration with the Spring Framework.
- ProxoolDriver no longer logs all SQLExceptions. It's up to the client to log exceptions as it sees fit. (With some changes to the tests, this means that we no longer get any stack traces output during testing when we encounter *expected* errors).
- Experimental DataSource implementation. Actually, we think it's ready for use but we haven't really had time to think about documenting it. We do have something though.
- Jakarta's Commons Logging is no longer bundled with the source and is now a dependency. We had forked this component (at their version 1.02) to make it simpler for us to deploy but there are advantages, particular with respect to configuration, to just using the component direct from Jakarta.
0.8.3 - 14 December 2003
- Switched to Cglib 2.0 and ASM 1.4. Repackaged them both to org.logicalcobwebs.clgib and org.logicalcobwebs.asm respectively. This means that you no longer need to include cglib in your classpath. (Note: other projects may still require it - the repackaged version is just for use by Proxool). This removes our dependency on any version of Cglib or ASM and avoids any potential Jar conflicts.
- Made house keeper connection test more robust - credit John Hume
- Removed JDK 1.4 specific code in ShutdownHook
0.8.2 - 5 November 2003
- Fixed bug where delegate properties weren't being passed onto the delegate driver. If you weren't passing any properties other than username and password to the delegate driver then this didn't cause a problem anyway. (Note that Proxool properties were being recognised correctly.) Added a new unit test specifically for this problem.
- Throw a friendlier exception if you try and add a statistics listener to a pool with no statistics
- Statistics now creates write locks less often. This was causing a problem during heavy loads even though the process of collecting statistics itself was very fast. If you had statistics turned off (the default) then this wasn't a problem anyway.
0.8.1 - October 27, 2003
- NullPointerException that occured during SQL logging for certain methods of excecuting statements has been fixed. Also, logging is optimised to do less work if nothing is listening. (No ConnectionListeners registered and log level not equal to debug or trace is off).
- Fixed typos in ShutdownHook. And now silently ignore IllegalStateException during removal of shutdownHook that occurs during JVM shut down.
0.8.0 - October 26, 2003
- We now use Cglib's proxy library. Together with dropping the use of Timer and only referencing ShutdownHooks at runtime we are now able to support JDKs 1.2, 1.3 and 1.4 out of the box (Without Ant applied patches, which were horrible).
- Proxool is now available as a JMX component.
- New getDelegateConnection() method on ProxoolFacade gives you access to the delegate (third party) driver if you really need it. This makes your project dependent on both Proxool (to a small extent) and your third party driver (to a bigger extent) so should be done only if necessary.
- If ProxoolDriver gets garbage collected for any reason (outside our control) then we no longer shutdown the pool it relates to.
- AdminServlet now displays times for maximum-conneciton-lifetime, house-keeping-sleep-time, and maximum-active-time properly regardless of your timezone. This was a display bug only and didn't effect the behaviour of the pool itself.
- Connections that are about to be expired no longer bother to reset themselves (because they'll never be used again anyway). This was causing problems if the connection had connectivity problems to the database which then caused problems during the reset.
- Added fatal-sql-exception-wrapper-class property. If a fatal exception is detected then it is wrapped up inside the exception defined by this property. This can make exception handling easier in frameworks like Struts. Two wrappers are provided (FataSQLException and FatalRuntimeException) but you can also define your own.
- Added test-before-use and test-after-use properties. They will trigger a test of the connection (as defined by house-keeper-test-sql) just before a connection is handed out and just after it is closed (put back in the pool) respectively. These are both off by default.
- Fixed ConcurrentModificationException that happened in some environments during automatic statement closure.
- Fixed bug where if there was an Error during prototyping (not an SQLException, not a RuntimeException but something serious like NoClassDefFoundError) then the prototyper would keep attempting to make connections as fast as it could (and never succeed in making any). Much better for the prototyper to give up in that situation and try again when it is next asked (which, by default, would be 30 seconds later).
- Fix to documentation. Defining more than one type of fatal SQL exception is done with a comma delimited list.
- Fix to ProxoolFacade.redefine() which was in fact doing an update instead of a redefine. This didn't have any consequences unless you were calling this method explicitly in your code.
- Made the 'Attempt to use a pool with incomplete definition' exception a bit more informative. It is often because you are refering to an unregistered pool by its alias.
- SQL command logging (using the 'trace' property) now embeds the parameters into the SQL (if the SQL is parametised). This means that the log is almost like a journal - with the exception that any callable statements that return data retain the ? (question marks) that contain the output parameters.
- Batched statements are now correctly reported with the trace feature.
0.7.2 - April 28, 2003
- Moved DataSourceTest into Sandbox so that the Ant test target runs correctly.
- Fixed a bug in ConfigurationListener that meant that if you passed a Properties object to the Driver when asking for a connection to an existing pool it incorrectly called ConfigurationListenerIF.definitionUpdated when there was no change, and didn't call it when there was.
0.7.1 - April 19, 2003
- Added a lot of concurrency code - mainly using concurrent package written by Doug Lea.
- Fixed display bug in AdminServlet - average active time was being displayed in milliseconds instead of seconds.
- Refactoring of how definitions are updated and redefined. Use ProxoolFacade.updateConnectionPool to make incremental changes and ProxoolFacade.redefineConnectionPool to reset the definition and start again. (If you pass a Properties object to the DriverManager when asking for a connection this will call redefineConnectionPool.)
- if you change the url or any of the delegate properties for a pool's definition then all existing connections are automatically killed so that new ones are created that conform to the new definition.
- Change to ConfigurationListenerIF API. defintionChanged is now called definitionChanged (stupid spelling error).
- ConnectionListenerIF.onDeath now gets called for all connections closed during shutdown.
- Pools manually removed (using ProxoolFacade.removeConnectionPool) are no longer attempted to be removed during shutdown.
- Maximum-new-connections property has been deprecated in favour of the more descriptive simultaneous-build-throttle property.
- Refactoring of house keeper and prototyper so that the number of threads used by Proxool is more scalable. (Proxool used to create two threads per pool).
- Moved AdminServlet to servlet sub-package to make way for upcoming JMX admin implementation.
- Fixed bug where ConfigurationListenerIF.definitionUpdated was getting called when you passed a Properties object to the Driver regardless if whether the definition had changed.
0.7 - February 21, 2003
- We have dropped the dependency on commons-logging.jar by copying the code into our own project (retaining credit to the Jakarta team, naturally).
- New Admin package provides statistical and snapshot information so you can measure how well Proxool, and your database, is doing.
- New AdminServlet provides statistical information for your web application.
- The JDK 1.2 patch code has been brought up to date and now passes all the unit tests.
- The listener code has been redone. Proxool now allows multiple listeners per pool. setFooListener has now been deprecated in favour of addFooListener. And it's now thread safe (just in case you add or remove a listener while the pool is running).
- The new ServletConfigurator will help you to configure and shutdown your pools simply by adding a few lines to your servlet configuration (web.xml) file and perhaps writing an XML file. No changes to your Java code.
- By using ShutdownHooks (with JDK1.3 or later) we get a cleaner, more reliable shutdown of the pools when the JVM stops.
- Removed ReloadMonitor (added in 0.5) because it made use of SystemProperties and this is prohbited by J2SE. You are now responsible for ensuring Proxool is shutdown if your application is reloaded within the same environment (as can sometimes happen in a web application). See ProxoolFacade.shutdown().
- Fixed bug when you asked DatabaseMetaData for the connection. It now gives you back the Proxool connection, not the underlying delegate connection.
- Fixed bug where if you registered, removed and then re-registered a pool then the new pool would not notice the Properties passed to it.
- If a connection encounters a fatal SQLException (as defined by the fatal-sql-exception property) it now wakes up the house keeper thread so other connections are tested as soon as possible (with the house-keeper-test-sql) rather than waiting for the next scheduled sweep.
0.6 - January 23, 2003
- ProxoolFacade API has changed slightly. Some of the methods no longer throw an SQLException but a ProxoolException instead. This might lead to some small changes in your code.
- There used to be some ambiguity about whether you referred to a pool by its alias or its full url (when using ProxoolFacade). This has now been fixed. This means you can now change the url (to use a different database for instance) without creating a new pool.
- Version information is now logged so you can tell what version of Proxool you are using.
- ConnectionPoolStatisticsIF now reports the time the pool was started.
- We now use FastArrayList (from Jakarta Commons) instead of the JDK's Vector for improved collection support.
- New JAXPConfigurator and PropertyConfigurator to make it easy to configure proxool from a file.
- New ConfigurationListenerIF interface allows you to implement a persistent configuration.
- Bug fix for JDBC drivers that implement the Statement interface indirectly (that is, extend a class that implements it rather than implementing it directly). (Credit to Martin Crawford).
- Unclosed Statements are now automatically closed when the Connection is closed, in accordance with the JDBC spec.
- Rollback is called on all connections when they are closed (that is, returned to the pool). This has no effect if autoCommit it true (default) or any pending transactions have been committed or already rolled back. This will only have an effect if you currently close connections with pending transactions.
- ProxoolFacade's new getDelegateStatement allows you to get to the underlying JDBC Driver's original Statement if you really need to. (This isn't recommended unless you have no other choice).
- You can now update the URL for a pool, not just the properties. See ProxoolFacade's updateConnectionPool.
0.5 - 3 December 2002
- Fix finalisation of old instances. If you deploy to some environments in a certain way then it is possible for the class to be reloaded without the finalize() method being called. This will result in spurious house keeping threads remaining. The new ReloadMonitor avoids this.
- Various improvements to the logging to make it more informative and cleaner.
- Checkstyle improvements. We now enforce variable names and line length. Javadoc enforcement to come soon.
- Made the onBirth() method of ConnectionListenerIF interface failsafe. And removed obsolete cleanupClob() method (which was never called anyway)..
- Removed redundant logFilename stuff from ConnectionPoolDefinition. All logging is handled by Jakarta Commons's Logging anyway.
- Fix when removing pools that meant that when you tried to add them again Proxool thought it was a duplicate (credit to Dan Milstein).
- Improvements to the way Proxool detects changes to the pool definition when resending the Properties object when you get a connection. Now detects when it has changed which means that we don't do unnecessary configuration and log is improved (we now log properties as they are set or updated).
- Fix to the ProxyConnection within the equals() method that was causing identical conections to be incorrectly reported as unequal (which leads to problems when adding them to some collections).
- Improvements to test classes. Lots more tests.
- Added support for resetting connection properties when it is returned to the pool (autoCommit, catalog, readOnly, transactionIsolation, typeMap and holdability). These properties are reset to the values when the connection was made everytime it is returned. (credit to Tim Morley)
- Connection.isClosed() now returns true when it is back in the pool.
- New trace property allows you to log each execution, the SQL, the parameters used, and the execution time (DEBUG level). Use proxool.trace=true property. You can also get this information if you register a ConnectionListenerIF (use ProxoolFacade's setConnectionListener() method). This won't effect performance if you're not listening or have trace off.
- Prototyping is now off by default. To enable prototyping you need to set the proxool.prototype-count property to something sensible (like 5, for instance). [Prototyping is where spare connections are when the number of available connections approaches zero.]
- Fix for catching fatal SQL exceptions. This is a feature that throws away connections that encounter certain types of exception.
0.4 - 19 September 2002
- Rethink of how we organise our source code so that we can easily build to include different optional components.
- Use the Jakarta Commons' ultra-thin log wrapper. This allows you to plugin whatever logging component you like.
- Switched to use of the Proxy class so that we are not tied to a particular version of the JDK. However, this does mean a bit of patching to work with JDK 1.2 (Proxy was introduced in 1.3). Fortunately, this patch is handled easily using Ant.
- Test classes now make use of Hypersonic. A pure Java database with a very small footprint. This means we can run the tests without having to rely on the existence of a separate database.
- Layout and code style changes in accordance with CheckStyle
- New XMLConfigurator using JAXP to configure your connection pools.
- Improvments in Junit testing.