This week's book giveaway is in the Servlets forum.
We're giving away four copies of Murach's Java Servlets and JSP and have Joel Murach on-line!
See this thread for details.
The moose likes Spring and the fly likes Spring Persistence with Hibernate - Transaction contexts across remote calls Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Murach's Java Servlets and JSP this week in the Servlets forum!
JavaRanch » Java Forums » Frameworks » Spring
Bookmark "Spring Persistence with Hibernate - Transaction contexts across remote calls" Watch "Spring Persistence with Hibernate - Transaction contexts across remote calls" New topic
Author

Spring Persistence with Hibernate - Transaction contexts across remote calls

Tauri Valor
Ranch Hand

Joined: Aug 03, 2005
Posts: 166
Hi Paul,

Most Application Servers support propagation of transaction contexts across remote calls, but the Spring Framework / Spring Container does not support propagation of transaction contexts across remote calls, so do you think theres any alternative other than EJB ?

Does the book talk about distributed transactions spanning multiple databases?

Thanks,
Tauri.


A Moment's insight is sometimes worth a Life's experience.
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17249
    
    6

The answer lies in responsibility. In an app server what is responsible for handlig these transactions, and that is the transaction manager. JTA Transaction manager. Spring can use a JTA Transaction manager and run in an app server. So in essence my point is, it isn't Spring's responsibility to do this. It is the server and tm which Spring gladly participates without having to do any jumping through hoops.

Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
Paul Fisher
author
Greenhorn

Joined: Jul 06, 2010
Posts: 23
Distributed transactions are not a primary focus of the book, but Spring is able to work with both local and distributed transactions — without requiring any code changes. This is one of the advantages of Spring: you are able to decouple these types of concerns to a matter of configuration. You can leverage JTA vs a local transaction provider simply by updating your Spring configuration.

--Paul
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Spring Persistence with Hibernate - Transaction contexts across remote calls
 
Similar Threads
BMP transaction propagation v nested transaction
Spring vs Other frameworks
Call Transactional Remote Session Bean From Spring
distibuted Transaction in Spring ?
Remote Transactions