-->
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.  [ 6 posts ] 
Author Message
 Post subject: JTA integration 'out of the box'
PostPosted: Thu Feb 24, 2005 2:17 pm 
Newbie

Joined: Thu Feb 24, 2005 1:44 pm
Posts: 11
Hibernate version: 2.1.8

I've been searching docs, forums, and google for how to get Hibernate to automatically work with JTA to registerSynchronization so that it automatically flushes and closes at the end of the JTA transaction. Obviously this goes hand-in-hand with thread local session and all that jazz.

I see in JBoss 3/4 there's a HibernateContext class that does exactly what I want, except that it depends on the JBoss TM, rather than using Hibernate's transaction.manager_lookup_class (which would make it portable across app servers).

I want a portable solution. Are there any plans to integrate such functionality into the core distribution?

Thanks,

- Jason


Top
 Profile  
 
 Post subject:
PostPosted: Thu Feb 24, 2005 3:44 pm 
Hibernate Team
Hibernate Team

Joined: Tue Sep 09, 2003 2:10 pm
Posts: 3246
Location: Passau, Germany
In Hibernate3 there are some settings afaik, check the javadoc for org.hibernate.cfg.Environment


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 25, 2005 7:03 pm 
Newbie

Joined: Thu Feb 24, 2005 1:44 pm
Posts: 11
There appears to be no support for this in Hibernate3.


Top
 Profile  
 
 Post subject:
PostPosted: Fri Feb 25, 2005 8:15 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 12:50 pm
Posts: 5130
Location: Melbourne, Australia
hibernate.transaction.flush_before_completion
hibernate.transaction.auto_flush_session


Top
 Profile  
 
 Post subject:
PostPosted: Sat Feb 26, 2005 1:04 pm 
Newbie

Joined: Thu Feb 24, 2005 1:44 pm
Posts: 11
Thanks Gavin.

The class JavaDoc comment for Environment has not yet been updated with these properties.


Top
 Profile  
 
 Post subject:
PostPosted: Sat Feb 26, 2005 1:38 pm 
Newbie

Joined: Thu Feb 24, 2005 1:44 pm
Posts: 11
I see in Hibernate3 there is extensive work on the JTA integration piece, but I still don't see anything like the JBoss HibernateContext that returns the same Session instance for all calls within the same tx. Am I just missing it?

Thanks,

- Jason


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 6 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.