Win a copy of Murach's Python Programming this week in the Jython/Python forum!
  • Post Reply Bookmark Topic Watch Topic
  • New Topic

can we use container managed transactions for any method in our java application?  RSS feed

 
raminaa niilian
Ranch Hand
Posts: 551
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Hi
Thank you for reading my post
I know somethings about Container managed Transaction but i have some questions

-can we use the container to handle and manage transactions of our Session bean and session facades ?
I mean for example we dynamically configure the system to execute a method in a transaction context?

-in Java EE 5, how we should describe the tranasactions ?
i read that all Java EE 5 stuff uses annotation and annotation can not be changed after a class compiled.


thanks
 
Paul Sturrock
Bartender
Posts: 10336
Eclipse IDE Hibernate Java
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator

-can we use the container to handle and manage transactions of our Session bean and session facades ?
I mean for example we dynamically configure the system to execute a method in a transaction context?

Yes - if the trans-attribute is "supports", and the client calling the EJB method does so within a transation. If the client doesn't call the method within a transaction then no transaction is used. Otherwise transactional behaviour is determined by the container (if CMT is defined for the method of course).
 
It is sorta covered in the JavaRanch Style Guide.
  • Post Reply Bookmark Topic Watch Topic
  • New Topic
Boost this thread!