Question
Container managed transaction VS Bean managed transaction difference
Hi
I have found the below in the LSA guide:
in BMT: A subsequent assignment or any other subsequent business operation can then rely on the results of the database write operations.
in CMT: No business operation within the transaction, yet occur
after the EJB response is sent, can rely on the results of the database write operations from the same transaction.
I dint get the exact intent of the statements.
What could be the usecase to use BMT vs CMT?
***Moderator Edit-Vidyaranjan: Moved from PSC to Academy***
CMT is used by services that support distributed transaction, JMS for example. The container oversees those transactions. If any transaction fails the entire distributed transaction is rolled back.