Win a copy of Functional Reactive Programming this week in the Other Languages forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

JTA or JDBC transaction

 
Edy Yu
Ranch Hand
Posts: 264
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
In one session bean, this transaction involves a bunch of SQL calls to database. But all of them are in the same method of this bean. I understand both JTA or regular JDBC level transaction control will work. Which one is prefered though?
Thanks in advance ...
 
Chris Mathews
Ranch Hand
Posts: 2712
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Since you are already using EJB, in this case Session Beans, then it is easiest to just go with CMT which will make use of JTA. However, if you didn't already have this infrastructure in place then I would have went with the simplist solution possible which in this case (without considering any other requirements that I don't know of) would mean plain JDBC.
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic