Back Forum Reply New

Stateless Session Support using Transactional Annotations?

Is there any support in spring for hibernate's stateless session?  I need to create a stateless session for my DAO's to use but I can't see how to do that.  Calling sessionFactory.openStatelessSession() doesn't seem to replace the sessionFactory.getCurrentSession() that my DAOs use.

FYI, there is an enhancement request in our JIRA: browse/SPR-2495

However, there is no such StatelessSession support at this time. It might happen in the 2.5.5/2.5.6 timeframe; if not, it's going to be for Spring 3.0.

The problem here is primarily that Hibernate has separate, completely unrelated interfaces for Session and StatelessSession. The existing quot;SessionFactory.getCurrentSession()quot; method cannot be used for a StatelessSession; we'll have to introduce a custom method for that in our Spring SessionFactoryUtils class.

Juergen

Thanks for the info.  I'll keep my eyes on that enhancement.

Can someone please let me know if this feature has been released in Spring 2.5.5?
¥
Back Forum Reply New