Originally posted by Ryan Wong:
In spec 7.6, it says that "If a transaction rolled back has been requested instead, the rollback status is reached without the container issuing a beforeCompletion. "
However, down below in the Notes 1, it says " The Container must call the afterBegin, beforeCompletion, and the afterCompletion methods if the session bean class implements directly or indrectly, the SessionSynchronization inferface"
How come notes 1 say this?
I think the note refers to the general implementation of the SessionSynchronization (i.e. in normal circumstances). The specs say clearly, as you stated, that the Container 'may not invoke beforeCompletion' if the transaction has been marked for rolled bacl. I found this question on a mock exam, and actually you are supposed to answer that the beforeCompletion method will not be invoked.
Marco Tedone<br />SCJP1.4,SCJP5,SCBCD,SCWCD