aries-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From cschnei...@apache.org
Subject svn commit: r1630071 - in /aries/trunk/jpa/jpa-container/src: main/java/org/apache/aries/jpa/container/impl/EntityManagerFactoryManager.java test/java/org/apache/aries/jpa/container/PersistenceBundleLifecycleTest.java
Date Wed, 08 Oct 2014 11:24:34 GMT
Author: cschneider
Date: Wed Oct  8 11:24:33 2014
New Revision: 1630071

URL: http://svn.apache.org/r1630071
Log:
ARIES-1247 Do not create EntityManagerFactory for status resolved

Modified:
    aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/EntityManagerFactoryManager.java
    aries/trunk/jpa/jpa-container/src/test/java/org/apache/aries/jpa/container/PersistenceBundleLifecycleTest.java

Modified: aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/EntityManagerFactoryManager.java
URL: http://svn.apache.org/viewvc/aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/EntityManagerFactoryManager.java?rev=1630071&r1=1630070&r2=1630071&view=diff
==============================================================================
--- aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/EntityManagerFactoryManager.java
(original)
+++ aries/trunk/jpa/jpa-container/src/main/java/org/apache/aries/jpa/container/impl/EntityManagerFactoryManager.java
Wed Oct  8 11:24:33 2014
@@ -170,8 +170,6 @@ public class EntityManagerFactoryManager
         //If we are Resolved as a result of having stopped
         //and missed the STOPPING event we need to unregister
         unregisterEntityManagerFactories();
-      //Create the EMF objects if necessary
-        createEntityManagerFactories();
         break;
         //Starting and active both require EMFs to be registered
       case Bundle.STARTING :

Modified: aries/trunk/jpa/jpa-container/src/test/java/org/apache/aries/jpa/container/PersistenceBundleLifecycleTest.java
URL: http://svn.apache.org/viewvc/aries/trunk/jpa/jpa-container/src/test/java/org/apache/aries/jpa/container/PersistenceBundleLifecycleTest.java?rev=1630071&r1=1630070&r2=1630071&view=diff
==============================================================================
--- aries/trunk/jpa/jpa-container/src/test/java/org/apache/aries/jpa/container/PersistenceBundleLifecycleTest.java
(original)
+++ aries/trunk/jpa/jpa-container/src/test/java/org/apache/aries/jpa/container/PersistenceBundleLifecycleTest.java
Wed Oct  8 11:24:33 2014
@@ -405,7 +405,6 @@ public class PersistenceBundleLifecycleT
     //Now try Resolving
     Skeleton.getSkeleton(persistenceBundle).setReturnValue(new MethodCall(Bundle.class, "getState"),
Bundle.RESOLVED);
     mgr.modifiedBundle(persistenceBundle, new BundleEvent(BundleEvent.RESOLVED, persistenceBundle),
o);
-    testSuccessfulCreationEvent(ref, extenderContext, 1);
     BundleContextMock.assertNoServiceExists(EntityManagerFactory.class.getName());
     
     
@@ -486,8 +485,6 @@ public class PersistenceBundleLifecycleT
     Skeleton.getSkeleton(persistenceBundle).setReturnValue(new MethodCall(Bundle.class, "getState"),
Bundle.RESOLVED);
     mgr.modifiedBundle(persistenceBundle, new BundleEvent(BundleEvent.RESOLVED, persistenceBundle),
getTrackedObject());
     
-    //We will have created the EMF a total of 2 times
-    testSuccessfulCreationEvent(ref, extenderContext, 2);
     BundleContextMock.assertNoServiceExists(EntityManagerFactory.class.getName());
   }
   



Mime
View raw message