|
From: <jue...@we...> - 2003-12-09 06:51:16
|
Matthew, =20 You should either use Spring-managed transactions (via = HibernateTransactionManager or JtaTransactionManager), which will = automatically flush a Session at transaction commit, or set = HibernateTemplate's/HibernateInterceptor's "flushMode" property to = FLUSH_EAGER (respectively "flushModeName" to "FLUSH_EAGER" in a textual = bean definition). This will guarantee to flush as early as possible, not = after view rendering: After all, a view should not modify the model, so = there should be no need to flush afterwards. =20 Juergen =20 ________________________________ Von: spr...@li... im Auftrag = von Matthew E. Porter Gesendet: Di 09.12.2003 02:20 An: spr...@li... Betreff: [Springframework-developer] OpenSessionInViewFilter I am attempting to use the OpenSessionInViewFilter. According to the javadoc, the session is not flush at the end of the filter. Therefore, without overriding the closeSession() method in the filter, how do I get the session to flush? I am currently accessing DAOs wrapped as a ProxyFactoryBean with a HibernateInterceptor. Please help! Cheers, matthew ------------------------------------------------------- This SF.net email is sponsored by: IBM Linux Tutorials. Become an expert in LINUX or just sharpen your skills. Sign up for = IBM's Free Linux Tutorials. Learn everything from the bash shell to sys = admin. Click now! http://ads.osdn.com/?ad_id=3D1278&alloc_id=3D3371&op=3Dclick _______________________________________________ Springframework-developer mailing list Spr...@li... https://lists.sourceforge.net/lists/listinfo/springframework-developer |