aries-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From mnutt...@apache.org
Subject svn commit: r1601602 - /aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/PersistenceBundleManager.java
Date Tue, 10 Jun 2014 10:53:40 GMT
Author: mnuttall
Date: Tue Jun 10 10:53:39 2014
New Revision: 1601602

URL: http://svn.apache.org/r1601602
Log:
Aries-1040: Exception during jpa-container shutdown. From a patch by Gert Vanthienen. 

Modified:
    aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/PersistenceBundleManager.java

Modified: aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/PersistenceBundleManager.java
URL: http://svn.apache.org/viewvc/aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/PersistenceBundleManager.java?rev=1601602&r1=1601601&r2=1601602&view=diff
==============================================================================
--- aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/PersistenceBundleManager.java
(original)
+++ aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/PersistenceBundleManager.java
Tue Jun 10 10:53:39 2014
@@ -310,7 +310,9 @@ public class PersistenceBundleManager im
   public void removedBundle(Bundle bundle, BundleEvent event, Object object) {
     EntityManagerFactoryManager mgr = (EntityManagerFactoryManager) object;   
     mgr.destroy();
-    persistenceUnitFactory.destroyPersistenceBundle(ctx, bundle);
+    if (!managersAwaitingProviders.contains(mgr)) {
+    	persistenceUnitFactory.destroyPersistenceBundle(ctx, bundle);
+    }
     //Remember to tidy up the map
     synchronized (this) {
       bundleToManagerMap.remove(bundle);



Mime
View raw message