[jboss-cvs] JBossCache/tests/functional/org/jboss/cache/optimistic ...
Manik Surtani
msurtani at jboss.com
Wed Sep 6 11:30:58 EDT 2006
User: msurtani
Date: 06/09/06 11:30:58
Modified: tests/functional/org/jboss/cache/optimistic
AbstractOptimisticTestCase.java CacheTest.java
ConcurrentTransactionTest.java
NodeInterceptorGetChildrenNamesTest.java
NodeInterceptorGetKeyValTest.java
NodeInterceptorGetKeysTest.java
NodeInterceptorKeyValTest.java
NodeInterceptorPutEraseTest.java
NodeInterceptorPutMapTest.java
NodeInterceptorRemoveDataTest.java
NodeInterceptorRemoveKeyValTest.java
NodeInterceptorRemoveNodeTest.java
NodeInterceptorTransactionTest.java
OpLockingInterceptorTest.java
OptimisticCreateIfNotExistsInterceptorTest.java
OptimisticReplicationInterceptorTest.java
OptimisticWithPassivationTest.java
ThreadedOptimisticCreateIfNotExistsInterceptorTest.java
TxInterceptorTest.java
Log:
Removed TreeCache dependency on ServiceMBeanSupport
Revision Changes Path
1.39 +16 -16 JBossCache/tests/functional/org/jboss/cache/optimistic/AbstractOptimisticTestCase.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: AbstractOptimisticTestCase.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/AbstractOptimisticTestCase.java,v
retrieving revision 1.38
retrieving revision 1.39
diff -u -b -r1.38 -r1.39
--- AbstractOptimisticTestCase.java 30 Aug 2006 21:05:16 -0000 1.38
+++ AbstractOptimisticTestCase.java 6 Sep 2006 15:30:58 -0000 1.39
@@ -77,8 +77,8 @@
protected TreeCache createCacheWithListener(CacheListener listener) throws Exception
{
TreeCache cache = createCacheUnstarted();
- cache.createService();
- cache.startService();
+ cache.create();
+ cache.start();
cache.getNotifier().addCacheListener(listener);
return cache;
}
@@ -118,8 +118,8 @@
Configuration c = cache.getConfiguration();
cache.setConfiguration(c);
c.setCacheLoaderConfiguration(getCacheLoaderConfig(true, getTempDir(), passivationEnabled));
- cache.createService();
- cache.startService();
+ cache.create();
+ cache.start();
return cache;
}
@@ -127,15 +127,15 @@
protected TreeCache createCache() throws Exception
{
TreeCache cache = createCacheUnstarted();
- cache.createService();
- cache.startService();
+ cache.create();
+ cache.start();
return cache;
}
protected void destroyCache(TreeCache c)
{
- c.stopService();
- c.destroyService();
+ c.stop();
+ c.destroy();
}
@@ -151,8 +151,8 @@
c.setCacheMode(Configuration.CacheMode.REPL_SYNC);
c.setIsolationLevel(IsolationLevel.REPEATABLE_READ);
c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
- cache.createService();
- cache.startService();
+ cache.create();
+ cache.start();
return cache;
@@ -171,8 +171,8 @@
c.setCacheMode(Configuration.CacheMode.LOCAL);
c.setIsolationLevel(IsolationLevel.REPEATABLE_READ);
c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
- cache.createService();
- cache.startService();
+ cache.create();
+ cache.start();
return cache;
@@ -218,8 +218,8 @@
}
c.setNodeLockingScheme("OPTIMISTIC");
c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
- cache.createService();
- cache.startService();
+ cache.create();
+ cache.start();
return cache;
}
@@ -254,8 +254,8 @@
c.setTransactionManagerLookupClass("org.jboss.cache.DummyTransactionManagerLookup");
c.setCacheLoaderConfiguration(getCacheLoaderConfig(shared, shared ? getTempDir(name + "-shared") : getTempDir(name + instanceNumber++), false));
- cache.createService();
- cache.startService();
+ cache.create();
+ cache.start();
return cache;
}
1.23 +2 -2 JBossCache/tests/functional/org/jboss/cache/optimistic/CacheTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: CacheTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/CacheTest.java,v
retrieving revision 1.22
retrieving revision 1.23
diff -u -b -r1.22 -r1.23
--- CacheTest.java 30 Aug 2006 21:05:16 -0000 1.22
+++ CacheTest.java 6 Sep 2006 15:30:58 -0000 1.23
@@ -64,7 +64,7 @@
{
Assert.assertTrue("Expecting a rollback exception!", true);
}
- c.stopService();
+ c.stop();
}
public void testImplicitTxFailure() throws Exception
@@ -101,7 +101,7 @@
{
Assert.assertNull("Thread " + thread[i].getName() + " threw exception!", thread[i].getException());
}
- c.stopService();
+ c.stop();
}
public void testLocalTransaction() throws Exception
1.4 +1 -1 JBossCache/tests/functional/org/jboss/cache/optimistic/ConcurrentTransactionTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: ConcurrentTransactionTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/ConcurrentTransactionTest.java,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -b -r1.3 -r1.4
--- ConcurrentTransactionTest.java 30 Aug 2006 21:05:16 -0000 1.3
+++ ConcurrentTransactionTest.java 6 Sep 2006 15:30:58 -0000 1.4
@@ -41,7 +41,7 @@
{
if (cache != null)
{
- cache.stopService();
+ cache.stop();
cache = null;
}
}
1.10 +140 -136 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetChildrenNamesTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorGetChildrenNamesTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetChildrenNamesTest.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- NodeInterceptorGetChildrenNamesTest.java 18 Aug 2006 15:40:40 -0000 1.9
+++ NodeInterceptorGetChildrenNamesTest.java 6 Sep 2006 15:30:58 -0000 1.10
@@ -1,6 +1,10 @@
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -92,7 +96,7 @@
assertEquals(0, cache.getChildrenNames("/").size());
mgr.commit();
- cache.stopService();
+ cache.stop();
}
@@ -144,7 +148,7 @@
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionGetNamesIteratorMethod() throws Exception
@@ -209,7 +213,7 @@
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
1.10 +208 -204 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeyValTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorGetKeyValTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeyValTest.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- NodeInterceptorGetKeyValTest.java 18 Aug 2006 15:40:40 -0000 1.9
+++ NodeInterceptorGetKeyValTest.java 6 Sep 2006 15:30:58 -0000 1.10
@@ -1,6 +1,10 @@
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -89,7 +93,7 @@
assertNull(cache.get("/one/two", "key1"));
mgr.commit();
- cache.stopService();
+ cache.stop();
}
public void testTransactionGetKeyValOverwriteMethod() throws Exception
@@ -148,7 +152,7 @@
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionGetKeyValOverwriteNullMethod() throws Exception
@@ -205,7 +209,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
@@ -298,7 +302,7 @@
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
1.10 +136 -132 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeysTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorGetKeysTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorGetKeysTest.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- NodeInterceptorGetKeysTest.java 18 Aug 2006 15:40:40 -0000 1.9
+++ NodeInterceptorGetKeysTest.java 6 Sep 2006 15:30:58 -0000 1.10
@@ -1,6 +1,10 @@
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -91,7 +95,7 @@
assertNull(cache.get("/one/two", "key1"));
mgr.commit();
- cache.stopService();
+ cache.stop();
}
@@ -141,7 +145,7 @@
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionGetKeysIteratorMethod() throws Exception
@@ -201,7 +205,7 @@
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
1.11 +231 -227 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorKeyValTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorKeyValTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorKeyValTest.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -b -r1.10 -r1.11
--- NodeInterceptorKeyValTest.java 18 Aug 2006 15:40:40 -0000 1.10
+++ NodeInterceptorKeyValTest.java 6 Sep 2006 15:30:58 -0000 1.11
@@ -1,6 +1,10 @@
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -74,7 +78,7 @@
assertEquals(1, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionKeyValOverwriteMethod() throws Exception
@@ -131,7 +135,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionKeyValOverwriteNullMethod() throws Exception
@@ -186,7 +190,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
@@ -245,7 +249,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTwoTransactionAdditionKeyValMethod() throws Exception
@@ -332,7 +336,7 @@
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
1.10 +143 -139 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutEraseTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorPutEraseTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutEraseTest.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- NodeInterceptorPutEraseTest.java 18 Aug 2006 15:40:40 -0000 1.9
+++ NodeInterceptorPutEraseTest.java 6 Sep 2006 15:30:58 -0000 1.10
@@ -1,6 +1,10 @@
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -77,7 +81,7 @@
assertEquals(1, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionKeyValOverwriteMethod() throws Exception
@@ -134,7 +138,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionKeyValOverwriteNullMethod() throws Exception
@@ -189,7 +193,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
1.10 +151 -147 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutMapTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorPutMapTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorPutMapTest.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- NodeInterceptorPutMapTest.java 18 Aug 2006 15:40:40 -0000 1.9
+++ NodeInterceptorPutMapTest.java 6 Sep 2006 15:30:58 -0000 1.10
@@ -1,6 +1,10 @@
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -80,7 +84,7 @@
assertEquals(1, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionPutLocalOverwriteDataMethod() throws Exception
@@ -139,7 +143,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionPutLocalEmptyMethod() throws Exception
@@ -197,6 +201,6 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
}
1.11 +173 -169 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveDataTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorRemoveDataTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveDataTest.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -b -r1.10 -r1.11
--- NodeInterceptorRemoveDataTest.java 18 Aug 2006 15:40:40 -0000 1.10
+++ NodeInterceptorRemoveDataTest.java 6 Sep 2006 15:30:58 -0000 1.11
@@ -1,6 +1,10 @@
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -74,7 +78,7 @@
assertEquals(1, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionRemoveEmptyMethod() throws Exception
@@ -131,7 +135,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionRemoveDataMethod() throws Exception
@@ -190,7 +194,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
@@ -250,6 +254,6 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
}
1.10 +132 -128 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveKeyValTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorRemoveKeyValTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveKeyValTest.java,v
retrieving revision 1.9
retrieving revision 1.10
diff -u -b -r1.9 -r1.10
--- NodeInterceptorRemoveKeyValTest.java 18 Aug 2006 15:40:40 -0000 1.9
+++ NodeInterceptorRemoveKeyValTest.java 6 Sep 2006 15:30:58 -0000 1.10
@@ -6,7 +6,11 @@
*/
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -81,7 +85,7 @@
assertEquals(1, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionRemoveNoKeyValMethod() throws Exception
@@ -139,7 +143,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionRemoveKeyValMethod() throws Exception
@@ -196,6 +200,6 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
}
1.12 +375 -370 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveNodeTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorRemoveNodeTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorRemoveNodeTest.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -b -r1.11 -r1.12
--- NodeInterceptorRemoveNodeTest.java 18 Aug 2006 15:40:40 -0000 1.11
+++ NodeInterceptorRemoveNodeTest.java 6 Sep 2006 15:30:58 -0000 1.12
@@ -6,7 +6,12 @@
*/
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
+import org.jboss.cache.TreeNode;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
@@ -81,7 +86,7 @@
assertEquals(null, dummy.getCalled());
assertEquals(0, listener.getNodesAdded());
- cache.stopService();
+ cache.stop();
}
public void testTransactionRemoveNodeMethod() throws Exception
@@ -141,7 +146,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
@@ -203,7 +208,7 @@
assertEquals(2, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testTransactionRemoveTwiceMethod() throws Exception
@@ -286,7 +291,7 @@
assertEquals(3, entry.getModifications().size());
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
@@ -372,7 +377,7 @@
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
assertEquals(4, listener.getNodesAdded());
- cache.stopService();
+ cache.stop();
}
@@ -460,7 +465,7 @@
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
assertEquals(3, listener.getNodesAdded());
- cache.stopService();
+ cache.stop();
}
public void testTransactionRemoveSubNodeMethod() throws Exception
@@ -532,6 +537,6 @@
assertTrue(!cache.exists("/one/two"));
assertEquals(null, dummy.getCalled());
assertEquals(2, listener.getNodesAdded());
- cache.stopService();
+ cache.stop();
}
}
1.8 +72 -72 JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorTransactionTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: NodeInterceptorTransactionTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/NodeInterceptorTransactionTest.java,v
retrieving revision 1.7
retrieving revision 1.8
diff -u -b -r1.7 -r1.8
--- NodeInterceptorTransactionTest.java 17 Aug 2006 21:57:59 -0000 1.7
+++ NodeInterceptorTransactionTest.java 6 Sep 2006 15:30:58 -0000 1.8
@@ -55,7 +55,7 @@
assertTrue(true);
}
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
public void testNoTransactionGetMethod() throws Exception
@@ -87,7 +87,7 @@
}
assertTrue(fail);
assertEquals(null, dummy.getCalled());
- cache.stopService();
+ cache.stop();
}
1.15 +322 -322 JBossCache/tests/functional/org/jboss/cache/optimistic/OpLockingInterceptorTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: OpLockingInterceptorTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OpLockingInterceptorTest.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -b -r1.14 -r1.15
--- OpLockingInterceptorTest.java 25 Aug 2006 14:10:10 -0000 1.14
+++ OpLockingInterceptorTest.java 6 Sep 2006 15:30:58 -0000 1.15
@@ -18,10 +18,10 @@
import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
import org.jboss.cache.loader.SamplePojo;
import org.jboss.cache.lock.IdentityLock;
+import org.jboss.cache.marshall.MethodCall;
import org.jboss.cache.marshall.MethodCallFactory;
import org.jboss.cache.marshall.MethodDeclarations;
import org.jboss.cache.transaction.DummyTransactionManager;
-import org.jboss.cache.marshall.MethodCall;
import javax.transaction.Transaction;
import java.util.HashMap;
@@ -131,7 +131,7 @@
mgr.commit();
- cache.stopService();
+ cache.stop();
}
@@ -248,7 +248,7 @@
assertEquals(MethodDeclarations.commitMethod, dummy.getCalled());
mgr.commit();
- cache.stopService();
+ cache.stop();
}
@@ -364,7 +364,7 @@
assertEquals(MethodDeclarations.rollbackMethod, dummy.getCalled());
mgr.commit();
- cache.stopService();
+ cache.stop();
}
1.11 +121 -117 JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticCreateIfNotExistsInterceptorTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: OptimisticCreateIfNotExistsInterceptorTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticCreateIfNotExistsInterceptorTest.java,v
retrieving revision 1.10
retrieving revision 1.11
diff -u -b -r1.10 -r1.11
--- OptimisticCreateIfNotExistsInterceptorTest.java 18 Aug 2006 15:40:40 -0000 1.10
+++ OptimisticCreateIfNotExistsInterceptorTest.java 6 Sep 2006 15:30:58 -0000 1.11
@@ -6,7 +6,11 @@
*/
package org.jboss.cache.optimistic;
-import org.jboss.cache.*;
+import org.jboss.cache.Fqn;
+import org.jboss.cache.GlobalTransaction;
+import org.jboss.cache.OptimisticTransactionEntry;
+import org.jboss.cache.TransactionTable;
+import org.jboss.cache.TreeCache;
import org.jboss.cache.interceptors.Interceptor;
import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
import org.jboss.cache.loader.SamplePojo;
@@ -49,7 +53,7 @@
// create a gtx
gtx = cache.getCurrentTransaction();
tx = txManager.getTransaction();
- entry = (OptimisticTransactionEntry) table.get( gtx );
+ entry = (OptimisticTransactionEntry) table.get(gtx);
workspace = entry.getTransactionWorkSpace();
// set invocation context elements
@@ -89,7 +93,7 @@
assertEquals(2, listener.getNodesAdded());
txManager.commit();
- cache.stopService();
+ cache.stop();
}
@@ -141,7 +145,7 @@
}
assertEquals(2, listener.getNodesAdded());
- cache.stopService();
+ cache.stop();
}
@@ -178,7 +182,7 @@
txManager.commit();
- cache.stopService();
+ cache.stop();
}
1.16 +757 -749 JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticReplicationInterceptorTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: OptimisticReplicationInterceptorTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticReplicationInterceptorTest.java,v
retrieving revision 1.15
retrieving revision 1.16
diff -u -b -r1.15 -r1.16
--- OptimisticReplicationInterceptorTest.java 25 Aug 2006 14:10:10 -0000 1.15
+++ OptimisticReplicationInterceptorTest.java 6 Sep 2006 15:30:58 -0000 1.16
@@ -11,17 +11,25 @@
import org.jboss.cache.TransactionTable;
import org.jboss.cache.TreeCache;
import org.jboss.cache.config.Configuration;
-import org.jboss.cache.interceptors.*;
+import org.jboss.cache.interceptors.Interceptor;
+import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
+import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
+import org.jboss.cache.interceptors.OptimisticReplicationInterceptor;
+import org.jboss.cache.interceptors.TxInterceptor;
import org.jboss.cache.loader.SamplePojo;
+import org.jboss.cache.marshall.MethodCall;
import org.jboss.cache.marshall.MethodCallFactory;
import org.jboss.cache.marshall.MethodDeclarations;
import org.jboss.cache.transaction.DummyTransactionManager;
import org.jgroups.Address;
-import org.jboss.cache.marshall.MethodCall;
import javax.transaction.RollbackException;
import javax.transaction.Transaction;
-import java.io.*;
+import java.io.DataInputStream;
+import java.io.DataOutputStream;
+import java.io.IOException;
+import java.io.ObjectInput;
+import java.io.ObjectOutput;
import java.util.ArrayList;
import java.util.List;
@@ -89,7 +97,7 @@
assertEquals(MethodDeclarations.optimisticPrepareMethod, calls.get(0));
assertEquals(MethodDeclarations.commitMethod, calls.get(1));
- cache.stopService();
+ cache.stop();
}
@@ -136,7 +144,7 @@
assertEquals(1, calls.size());
assertEquals(MethodDeclarations.rollbackMethod, calls.get(0));
- cache.stopService();
+ cache.stop();
}
@@ -267,7 +275,7 @@
assertEquals(1, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(1, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -415,7 +423,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -542,7 +550,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -664,7 +672,7 @@
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -812,7 +820,7 @@
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -904,8 +912,8 @@
assertEquals(MethodDeclarations.optimisticPrepareMethod, calls2.get(0));
assertEquals(MethodDeclarations.commitMethod, calls2.get(1));
- cache.stopService();
- cache2.stopService();
+ cache.stop();
+ cache2.stop();
}
@@ -1008,8 +1016,8 @@
assertEquals(MethodDeclarations.rollbackMethod, calls2.get(0));
- cache.stopService();
- cache2.stopService();
+ cache.stop();
+ cache2.stop();
}
@@ -1114,8 +1122,8 @@
assertEquals(0, calls2.size());
- cache.stopService();
- cache2.stopService();
+ cache.stop();
+ cache2.stop();
}
}
1.12 +81 -81 JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticWithPassivationTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: OptimisticWithPassivationTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/OptimisticWithPassivationTest.java,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -b -r1.11 -r1.12
--- OptimisticWithPassivationTest.java 20 Jul 2006 09:03:54 -0000 1.11
+++ OptimisticWithPassivationTest.java 6 Sep 2006 15:30:58 -0000 1.12
@@ -51,8 +51,8 @@
TreeCache cache = createCacheUnstarted(false);
cache.getConfiguration().setCacheLoaderConfiguration(getCacheLoaderConfig(getTempDir()));
- cache.createService();
- cache.startService();
+ cache.create();
+ cache.start();
return cache;
}
1.17 +2 -2 JBossCache/tests/functional/org/jboss/cache/optimistic/ThreadedOptimisticCreateIfNotExistsInterceptorTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: ThreadedOptimisticCreateIfNotExistsInterceptorTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/ThreadedOptimisticCreateIfNotExistsInterceptorTest.java,v
retrieving revision 1.16
retrieving revision 1.17
diff -u -b -r1.16 -r1.17
--- ThreadedOptimisticCreateIfNotExistsInterceptorTest.java 30 Aug 2006 20:01:58 -0000 1.16
+++ ThreadedOptimisticCreateIfNotExistsInterceptorTest.java 6 Sep 2006 15:30:58 -0000 1.17
@@ -113,7 +113,7 @@
}
assertEquals((2 * numThreads), listener.getNodesAdded());
- cache.stopService();
+ cache.stop();
}
public void testDifferentThreadsSameTransaction() throws Exception
@@ -186,7 +186,7 @@
TestingUtil.sleepThread((long) 4000);
assertEquals(2, listener.getNodesAdded());
- cache.stopService();
+ cache.stop();
}
public static Test suite()
1.15 +933 -930 JBossCache/tests/functional/org/jboss/cache/optimistic/TxInterceptorTest.java
(In the diff below, changes in quantity of whitespace are not shown.)
Index: TxInterceptorTest.java
===================================================================
RCS file: /cvsroot/jboss/JBossCache/tests/functional/org/jboss/cache/optimistic/TxInterceptorTest.java,v
retrieving revision 1.14
retrieving revision 1.15
diff -u -b -r1.14 -r1.15
--- TxInterceptorTest.java 25 Aug 2006 14:10:10 -0000 1.14
+++ TxInterceptorTest.java 6 Sep 2006 15:30:58 -0000 1.15
@@ -10,14 +10,17 @@
import org.jboss.cache.OptimisticTransactionEntry;
import org.jboss.cache.TransactionTable;
import org.jboss.cache.TreeCache;
-import org.jboss.cache.interceptors.*;
+import org.jboss.cache.interceptors.Interceptor;
+import org.jboss.cache.interceptors.OptimisticCreateIfNotExistsInterceptor;
+import org.jboss.cache.interceptors.OptimisticNodeInterceptor;
+import org.jboss.cache.interceptors.OptimisticReplicationInterceptor;
+import org.jboss.cache.interceptors.TxInterceptor;
import org.jboss.cache.loader.SamplePojo;
+import org.jboss.cache.marshall.MethodCall;
import org.jboss.cache.marshall.MethodCallFactory;
import org.jboss.cache.marshall.MethodDeclarations;
-import org.jboss.cache.marshall.MethodCall;
import org.jboss.cache.transaction.DummyTransactionManager;
import org.jgroups.Address;
-import org.jboss.cache.marshall.MethodCall;
import javax.transaction.Transaction;
import java.io.DataInputStream;
@@ -127,7 +130,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -171,7 +174,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -211,7 +214,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
public void testEmptyRollbackLocalTransaction() throws Exception
@@ -250,7 +253,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -306,7 +309,7 @@
assertNull(mgr.getTransaction());
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -354,7 +357,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -471,7 +474,7 @@
//assert we have the tx in th table
assertEquals(1, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(1, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
public void testRemotePrepareSuspendTransaction() throws Exception
@@ -600,7 +603,7 @@
assertNull(table.getLocalTransaction(gtx));
//assert we are no longer associated
assertEquals(null, mgr.getTransaction());
- cache.stopService();
+ cache.stop();
}
public void testRemoteCommitSuspendTransaction() throws Exception
@@ -739,7 +742,7 @@
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
assertEquals(null, mgr.getTransaction());
- cache.stopService();
+ cache.stop();
}
public void testRemoteRollbackSuspendTransaction() throws Exception
@@ -877,7 +880,7 @@
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
assertEquals(null, mgr.getTransaction());
- cache.stopService();
+ cache.stop();
}
public void testRemoteCommitTransaction() throws Exception
@@ -1018,7 +1021,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
assertNull(mgr.getTransaction());
- cache.stopService();
+ cache.stop();
}
@@ -1154,7 +1157,7 @@
assertEquals(0, cache.getTransactionTable().getNumGlobalTransactions());
assertEquals(0, cache.getTransactionTable().getNumLocalTransactions());
- cache.stopService();
+ cache.stop();
}
@@ -1204,7 +1207,7 @@
assertEquals(MethodDeclarations.optimisticPrepareMethod, calls.get(2));
assertEquals(MethodDeclarations.commitMethod, calls.get(3));
- cache.stopService();
+ cache.stop();
}
}
More information about the jboss-cvs-commits
mailing list