SEAM2.0.0.GA
JBOSS4.2.1.GA
I'm currently using multiple SMPC's (for multiple DB's) that are configured in the components.xml. Also using flushMode=MANUAL for @Begin method to ensure that transactions are atomic (i.e. no premature updates before conversation ends). Seems to be working ok so far!
I'm trying to understand the impact of the below statement from the ref pdf. It sounds like Seam is violating the EJB3 spec in this regard. This part is what I'm concerned about:
However as the Seammanaged persistence context is propagated to any component within the conversation, it will be propagated to
methods marked REQUIRES_NEW.
If you are using EJB3 and mark your class or method @TransactionAttribute(REQUIRES_NEW) then the transaction
and persistence context shouldn't be propagated to method calls on this object. However as the Seammanaged
persistence context is propagated to any component within the conversation, it will be propagated to
methods marked REQUIRES_NEW. Therefore, if you mark a method REQUIRES_NEW then you should access the entity
manager using @PersistenceContext.
Yes, the SMPC should not be used (as the manual says) if you are using a method marked REQUIRES_NEW. There is an open issue in JIRA about trying to detect this and throw an exception.
For now, its up to you to enforce this yourself...