File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes EJB and other Java EE Technologies and the fly likes Transactions in EJB Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Transactions in EJB" Watch "Transactions in EJB" New topic
Author

Transactions in EJB

Mrutyunjay Hanchinal
Ranch Hand

Joined: Sep 26, 2001
Posts: 50
Hi all
I am experiencing a problem with handling transactions in EJB
My application has the following
1. A servlet invokes a business method in stateful session bean "SFBean"
2. "SFBean" uses a helper class "Helper" to process some business logic.
3. In "Helper" I make use of two entity beans (BMP)
Here my problem is that I want the use of two entity beans as a single transaction.
If I start a UserTransaction in "Helper" I am getting not supported Exception as nested transactions are not allowed
Can any body suggest me How Do I go abt solving this
Thanks in anticipation
Mrutyunjay
Kyle Brown
author
Ranch Hand

Joined: Aug 10, 2001
Posts: 3892
    
    5
Build a stateless session bean and call your BMP's from within that.
Kyle
------------------
Kyle Brown,
Author of Enterprise Java (tm) Programming with IBM Websphere
See my homepage at http://members.aol.com/kgb1001001 for other WebSphere information.


Kyle Brown, Author of Persistence in the Enterprise and Enterprise Java Programming with IBM Websphere, 2nd Edition
See my homepage at http://www.kyle-brown.com/ for other WebSphere information.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Transactions in EJB