-
1. Re: two transactions, one entityManager
knaas Apr 30, 2007 3:34 PM (in response to knaas)I also failed to mention that I have tried MANUAL and AUTO flush mode with no change in behavior.
I have also tried manually creating a nested conversation in the action and then popping it at the end. No change in behavior. -
2. Re: two transactions, one entityManager
vralev Apr 30, 2007 5:01 PM (in response to knaas)I think this will work if you use the factory to create separate EMs:
@PersistenceUnit javax.persistence.EntityManagerFactory emf;
then:EntityManager em1 = emf.createEntityManager(); ...
-
3. Re: two transactions, one entityManager
pmuir Apr 30, 2007 5:22 PM (in response to knaas)Or of course you could create two Seam entity managers in components.xml. You'll need to make sure you load the alerts using the alternative entity manager.
-
4. Re: two transactions, one entityManager
knaas May 1, 2007 12:10 PM (in response to knaas)Thanks petemuir and vladimir.
The approach that we decide to take was to connect the modal dialog to a @WebRemote. This isolates the alert transaction to a separate conversation. It is probably better this way since I don't have to worry about JSF restoring the view each time we ask for more alerts from the server. Thus, as expected, performance is considerably faster.