[wildfly-dev] blocking JPA issue with resources getting de-listed from transaction too early on WildFly 8.x + master...

Scott Marlow smarlow at redhat.com
Mon Aug 25 11:27:07 EDT 2014


To address a leak with some resource adapters, WildFly is de-listing 
resources during the (IronJacamar) Synchronization.beforeCompletion 
time, however this can happen before all of the persistence providers 
have saved their changes to the database.  This is likely to be the case 
for applications that have more than one persistence unit used per 
transaction.  The impact is that only the first referenced persistence 
provider, is part of the transaction.  The other database changes will 
run as local database changes.  This was reported recently via [1] + [2] 
+ [3].  Discussion about how to best address is ongoing (would be nice 
to have both the resource leak fix and a way to run the IronJacamar 
Synchronization.beforeCompletion last).

This is a blocking issue for any jiras that we create to handle this. 
This problem is not in earlier application server versions (only in 
WildFly 8.0 and higher).

Workaround:

Using a single persistence unit per transaction should workaround this 
but a code fix will be better.

Scott

[1] WF user forum description of problem 
https://community.jboss.org/message/901613

[2] Narayana dev mailing list post about sync ordering 
https://community.jboss.org/message/901880

[3] original jira that reported this issue that I rejected 
https://issues.jboss.org/browse/WFLY-3619


More information about the wildfly-dev mailing list