|
From: Rod J. <rod...@in...> - 2003-11-03 18:08:39
|
Hi Guys, I've done the following refactoring to the JDBC packages: - Reworked SQLException translation. Now there's a SQLErrorCodes factory, not a SQLExceptionTranslator factory. This allows the SQLErrorCodeSQLExceptionTranslator to be subclassed for custom translation. There's a new protected customTranslate() method for a first shot at translation. If it returns null (as the SQLErrorCodeSQLExceptionTranslator implementation does) resolution is via the codes. I've added tests for error code lookup. - Refactored the jdbc.object package to pull the JdbcTemplate field and related properties into RdbmsOperation. - This enables multiple RdbmsOperation objects to be created with one JdbcTemplate. Instead of always creating their own JdbcTemplate, an RdbmsOperation exposes a JdbcTemplate bean property and (for some subclasses) constructor argument. This is appropriate for example if you want to set up custom configuration in the JdbcTemplate such as custom exception translators, warning policy etc. I've improved the test suite. Hopefully there won't be any nasty surprises, but please let me know if there are any implications I've overlooked. Regards, Rod |