-
Container Managed Transactions in WebSphere 6.0 (2 messages)
- Posted by: Winsome Bennett
- Posted on: October 13 2009 10:27 EDT
I have an EJB project running in WebSphere 6.0. I am using stateless session beans. The project is configured to use container managed transactions. I understand that transactions are required by default in EJBs, unless one specifies otherwise. That means that under usual circumstances when a business method is executed on a bean, the container starts a transaction. What happens in a business method that does not do an update, lets say it selects some information from the database and returns it? Does it still start a transaction and if so, Does it commit at the end of the method?Threaded Messages (2)
- Yes, a transaction is started by Winsome Bennett on March 21 2010 19:43 EDT
- Don't use the defaults by Dsasasa Msasasa on April 10 2010 17:42 EDT
-
Yes, a transaction is started[ Go to top ]
- Posted by: Winsome Bennett
- Posted on: March 21 2010 19:43 EDT
- in response to Winsome Bennett
Yes, a transaction is started be it reading or writing. -
Don't use the defaults[ Go to top ]
- Posted by: Dsasasa Msasasa
- Posted on: April 10 2010 17:42 EDT
- in response to Winsome Bennett
For CRUD operations, I would use Tx.REQUIRED for Create, Updates, Deletes and Tx.SUPPORTS for Reads