aspose file tools*
The moose likes EJB and other Java EE Technologies and the fly likes Why just marking and not rolling back? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Java » EJB and other Java EE Technologies
Bookmark "Why just marking and not rolling back?" Watch "Why just marking and not rolling back?" New topic
Author

Why just marking and not rolling back?

Hussein Baghdadi
clojure forum advocate
Bartender

Joined: Nov 08, 2003
Posts: 3476

Hi.
setRollbackOnly() method in CMT beans informs the transaction manager that this transaction is marked to be rolled-back.
Why this marking thing? why not rollback immediately?
Thanks.
Roger Chung-Wee
Ranch Hand

Joined: Sep 29, 2002
Posts: 1683
A CMT bean marks a transaction for rollback to protect data integrity before throwing an application exception, because application exceptions do not automatically cause the EJB container to rollback the transaction.


SCJP 1.4, SCWCD 1.3, SCBCD 1.3
Edvins Reisons
Ranch Hand

Joined: Dec 11, 2006
Posts: 364
John,

CMT means container - managed
 
wood burning stoves
 
subject: Why just marking and not rolling back?
 
Similar Threads
Transaction Rollback not rolling back the Database updates !!
Rollback
Corba.TRANSACTION_ROLLEDBACK after 3 method invokations
transaction rollback exception...
Doubt regarding transaction context