|
From: Colin S. <col...@ex...> - 2003-08-25 18:02:28
|
I want to use SingleConnectionDataSource with Hibernate, so I can wrap a connection I get from a Hibernate Session, and feed it as a DataSource to JDBCTemplate/JDBCHelper. However, right now I've had to make my own variant since the current code always calls source.setAutoCommit(true); in the init() method. This seems very arbitrary to me. At least in the case when the class is given an existing connection, it should just assume the commit option has been set appropriately on the connection. Even in the case when the class is opening the connection itself from an existing DataSource, there needs to be an option to set autoCommit either way. Regards, Colin |