|
From: Norris, T. <tys...@be...> - 2003-12-17 19:14:19
|
Hi All -=20 I'm trying to implement a very minimalist hibernate interface within our = application, and would like to do so without creating a Spring = application context. What I have working so far, and the problems with each: - extending HibernateDaoSupport - provides simple session = creation/access, but a new session is always created - extending HibernateDaoSupport; using = TransactionSynchronizationManager.initSynchronization() before getting = the HibernateTemplate - provides session creation and ThreadLocal = binding, but the session is never closed/removed (i.e. same session is = used indefinitely). I realize I will need to create some transactional boundaries to = properly handle this situation - any advice on how to do so easily? This solution need to operate within and without SLSB transactions.=20 My next approach will be to manually create a UserTransaction before the = query inits, and commit/rollback after my series of queries - similar to = the ThreadLocal-session-via-servlet-filter pattern.=20 I'm using weblogic, btw. thanks for any feedback tyson > This electronic transmission (and any attached document or file) is = confidential and intended for the sole use of the individual's) to whom = it is addressed. Any further distribution or copying of this message is = strictly prohibited. If you received this message in error, please = notify the sender, and destroy the message (and attached files), = immediately. BenefitPoint is not liable for any use or misuse contrary = to these directions >=20 >=20 |