Constructor Detail

DataSourceUtils

Method Detail

getConnection

Obtain a Connection from the given DataSource. Translates SQLExceptions into
the Spring hierarchy of unchecked generic data access exceptions, simplifying
calling code and making any exception that is thrown more meaningful.

Is aware of a corresponding Connection bound to the current thread, for example
when using DataSourceTransactionManager. Will bind a Connection to the
thread if transaction synchronization is active, e.g. when running within a
JTA transaction).

Is aware of a corresponding Connection bound to the current thread, for example
when using DataSourceTransactionManager. Will bind a Connection to the thread
if transaction synchronization is active (e.g. if in a JTA transaction).

getTargetConnection

Return the innermost target Connection of the given Connection. If the given
Connection is a proxy, it will be unwrapped until a non-proxy Connection is
found. Otherwise, the passed-in Connection will be returned as-is.