openjpa-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From curti...@apache.org
Subject svn commit: r961510 - /openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/datacache/TestClearableScheduler.java
Date Wed, 07 Jul 2010 21:21:41 GMT
Author: curtisr7
Date: Wed Jul  7 21:21:39 2010
New Revision: 961510

URL: http://svn.apache.org/viewvc?rev=961510&view=rev
Log:
OPENJPA-1692: Comment out failing case in TestClearableScheduler while this change is backed
out.

Modified:
    openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/datacache/TestClearableScheduler.java

Modified: openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/datacache/TestClearableScheduler.java
URL: http://svn.apache.org/viewvc/openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/datacache/TestClearableScheduler.java?rev=961510&r1=961509&r2=961510&view=diff
==============================================================================
--- openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/datacache/TestClearableScheduler.java
(original)
+++ openjpa/trunk/openjpa-persistence-jdbc/src/test/java/org/apache/openjpa/persistence/datacache/TestClearableScheduler.java
Wed Jul  7 21:21:39 2010
@@ -30,6 +30,7 @@ import org.apache.openjpa.datacache.Conc
 import org.apache.openjpa.datacache.DataCacheManager;
 import org.apache.openjpa.persistence.OpenJPAEntityManagerSPI;
 import org.apache.openjpa.persistence.datacache.common.apps.ScheduledEviction;
+import org.apache.openjpa.persistence.test.AllowFailure;
 import org.apache.openjpa.persistence.test.SingleEMFTestCase;
 
 public class TestClearableScheduler extends SingleEMFTestCase {
@@ -91,31 +92,32 @@ public class TestClearableScheduler exte
         assertEquals(2,cache2.getClearCount());
     }
     
-    public void testMultithreadedInitialization() throws Exception {
-        final OpenJPAConfiguration conf =  emf.getConfiguration();
-        final List<DataCacheManager> dcms = new Vector<DataCacheManager>();
-        Runnable r = new Runnable(){
-            public void run() {
-                dcms.add(conf.getDataCacheManagerInstance());
-            }
-        };
-        List<Thread> workers = new ArrayList<Thread>();
-        for(int i = 0;i<20;i++){
-            workers.add(new Thread(r));
-        }
-        for(Thread t : workers){
-            t.start();
-        }
-        for(Thread t : workers){
-            t.join();
-        }
-        DataCacheManager prev = dcms.get(0);
-        for(DataCacheManager dcm : dcms){
-            assertTrue(prev == dcm);
-            prev = dcm;
-        }
-
-    }
+// Comment this test out while investigating OPENJPA-1692
+//    public void testMultithreadedInitialization() throws Exception {
+//        final OpenJPAConfiguration conf =  emf.getConfiguration();
+//        final List<DataCacheManager> dcms = new Vector<DataCacheManager>();
+//        Runnable r = new Runnable(){
+//            public void run() {
+//                dcms.add(conf.getDataCacheManagerInstance());
+//            }
+//        };
+//        List<Thread> workers = new ArrayList<Thread>();
+//        for(int i = 0;i<20;i++){
+//            workers.add(new Thread(r));
+//        }
+//        for(Thread t : workers){
+//            t.start();
+//        }
+//        for(Thread t : workers){
+//            t.join();
+//        }
+//        DataCacheManager prev = dcms.get(0);
+//        for(DataCacheManager dcm : dcms){
+//            assertTrue(prev == dcm);
+//            prev = dcm;
+//        }
+//
+//    }
 
     /**
      * Pass in 4 out of 5 tokens.



Mime
View raw message