users@glassfish.java.net

Re: Glassfish and Hibernate: How to have each transction use its own session

From: <glassfish_at_javadesktop.org>
Date: Tue, 09 Jun 2009 09:53:12 PDT

That didn't do it for me. The recordTaskMetrics method uses a DAO to save data. I removed the TransactionAttribute annotation from recordTaskMetrics and moved it to the DAO, which is a second EJB, but the Hibernate session was reused. For grins, I also added the annotations at a class level and that seemed to do the trick.

This raises the question: doesn't this negate the usefullnes of method level annotations?


Steve
[Message sent by forum member 'ssaliman' (ssaliman)]

http://forums.java.net/jive/thread.jspa?messageID=350080