For container-managed transactions:
The transaction (TX) starts when the first transactional method is invoked. Per default, all EJB methods are transactional ( equivalent to
TransactionAttributeType.REQUIRED
, which is the default setting).The default TX propagation keeps the same TX over all local EJB calls. This is equivalent to an explicit
TrasactionAttributeType.REQUIRED
on all invoked methodsThe transaction is committed when the first method in the invocation chain (the one the TX has been created for) returns.
You can have a fine-grained control over the TX propagation by annotating your EJB methods with different TransactionAttributeTypes.