I have a Stateful session bean with three method preProcess, process and postProcess. the postProcess method marked with @Remove
these three methods are called in one method in a stateless session bean. After calling the postProcess the transaction is maked to rollback. I put a bunch of System.out to pring out getRollbackOnly() of the session context and I am sure no exception occured. At the point of returning from postProcess the log shows the getRollbackOnly() is false but in callee method right after this method getRollbackOnly() is true!!!
Does anybody know what the problem is?
@Remove
public void postProcess() {
....
logger.debug(sc.getRollbackOnly()); //prints out false
}
//in stateless SB
public void someMethod() {
mystateful.preProcess();
mystateful.process();
mystateful.postProcess();
logger.debug(sc.getRollbackOnly()); //prints out true!!!