• Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

MDBs and transactions

 
Prakash Dwivedi
Ranch Hand
Posts: 452
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
MDBs basically work asynchronously and are not part of transactions as well. But i was wondering is there a way they can behave synchronously and become part of a transaction?

The reason why i am asking is that i have to change the code of some old project, where lots of MDBs are called serially , These MDBs call Session Beans which in turn call CMPs. Now the calls to CMPs are not in single transaction, as they are called via MDB. Is there some way I can make all the calls to CMPs in one single transaction without removing MDBs and changing lots of code ?

Thanks
 
Brian Tinnel
Ranch Hand
Posts: 69
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
There is no way to make the MDB synchronous, but there are third party transaction managers that might allow an MDB to join an existing transaction. I would think that the code to do that would be much harder than converting the MDBs to stateless session beans.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic