-
May 16th, 2011, 03:34 PM
#1
How to use Spring 3.x JdbcTemplate with NO transaction?
Hi all,
I need to invoke some sql and it needs to be done outside a transaction. It's being done on a separate thread in a noncritical listener after the db work in my main thread commits.
I'm trying to use a new JdbcTemplate in the child thread, giving its constructor the DataSource that I'm using in my main thread, but there appears to be no way to turn autocommit back on via the new JdbcTemplate I'm using in the child thread. I don't see any properties allowing me to do that.
How can I invoke arbitrary SQL via JdbcTemplate and have it do the work outside a transaction?
Thanks,
Matthew
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules