• Post Reply Bookmark Topic Watch Topic
  • New Topic

CMT and DAO interaction  RSS feed

 
graham king
Ranch Hand
Posts: 133
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
I've got a situation where some transactions are left in an inconsistent state and am wondering where I'm going wrong.

A real simple architecture, SLS(2.0) --> DAO. After reading a few postings based on a 'CMT' search I found this article: Read the 2nd posting

I was wondering if the second posting still holds true? i.e., Do the SessionBeans still need to setRollbackOnly on the context?

TIA,

Graham
[ October 12, 2006: Message edited by: graham king ]
 
Vinay Raj
Ranch Hand
Posts: 81
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
If you are using a CMT SLSB you need not explicitly code for setRollback on the ejbContext object. The container will take care of transaction management. The only thing you need to ensure is that you are using the connection object obtained via the DataSource interface from the app. server's connection pool.

In case of BMT, you would need to explicitly code for setRollback.
 
graham king
Ranch Hand
Posts: 133
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Thanks for clearing that up, Vinay.
 
Don't get me started about those stupid light bulbs.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!