You call EJBContext.getRollBackOnly() when you want to find out if the transaction has been marked for rollback ...
Ok, I am confused here :roll:
EJBContext.getRollBackOnly() is for CMT only. It means, only container can call this method, right? If only container can call it then it is a container callback. (may be i am more confused than you initially thought )
EJBContext.getRollbackOnly() is for CMT and UserTx.getStatus() is for BMT. These two methods are called by the bean provider to know the status of the tx. getRollbackOnly() is used to find out whether the tx was set to rollback at any point using EJBContext.setRollbackOnly() regds Giju