srm: Use Spring JDBC support

Spring has extensive support for simplifying JDBC code. This patch updates
the srm to make use of Spring's JDBC support.

At the core of the patch is Spring's JdbcTemplate that provides methods
for common JDBC patterns. Given that the existing code was Connection
oriented, most uses of JdbcTemplate is for the ConnectionCallback pattern:
It encapsulates the acquisition, use and release of a Connection. There
are however plenty of other patterns, some of which are used in the patch.
A future patch may update more of the SRM code to make use of the higher
level patterns.

The patch also replaces most uses of SQLException. SQLExcepton is a catch
all JDBC exception. It has the problem that one has to inspect a vendor
specific error code to get more detailed information about the failure.
More over, a lot of SRM code is not JDBC specific, yet used the JDBC
exception. Eg JobStorage is not limited to JDBC, yet all methods threw
SQLException.

Spring provides the DataAccessException as a replacement for SQLException.
DataAccessException is a base class for an entire hierarchy of data
access related exceptions. Spring translates vendor specific SQL error
codes to an appropriate DataAccessException subclass. The translation
happens automatically when JdbcTemplate is used.

JdbcConnectionPool is now a factory of JdbcTemplate and TransactionTemplate.
It no longer provides methods for acquiring and releasing connections.

A consequence of the patch is that many errors that were previously caught
and ignored are now propagated.

Target: trunk
Require-notes: no
Require-book: no
Acked-by: Karsten Schwank <karsten.schwank@desy.de>
Patch: http://rb.dcache.org/r/5954/