-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 
Author Message
 Post subject: Container and Hibernate Transaction relationship
PostPosted: Thu Jan 22, 2004 3:44 pm 
Regular
Regular

Joined: Wed Jan 07, 2004 5:16 pm
Posts: 65
Location: CA, USA
A Transaction is started from an EJB as a Container Managed Transaction and then I call a DAO to execute some Hibernate code:

- is the Hibernate code implicitly part of the EJB transaction, or do you still have to call session.beginTransaction() within the Hibernate code to join the transaction already in progress?

If the EJB transaction rolls back, is the Hibernate code automatically rolled back, or do I have to detect this and then call rolback on the Hibernate transaction code?


Top
 Profile  
 
 Post subject:
PostPosted: Thu Jan 22, 2004 5:31 pm 
Hibernate Team
Hibernate Team

Joined: Tue Sep 09, 2003 2:10 pm
Posts: 3246
Location: Passau, Germany
This is done automatically. You may however include hibernate transaction handling code, to keep the code portable between application server and non application server.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 2 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.