cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From dk...@apache.org
Subject svn commit: r1347053 - in /cxf/branches/2.5.x-fixes: ./ systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/
Date Wed, 06 Jun 2012 19:02:08 GMT
Author: dkulp
Date: Wed Jun  6 19:02:07 2012
New Revision: 1347053

URL: http://svn.apache.org/viewvc?rev=1347053&view=rev
Log:
Merged revisions 1345415 via  svn merge from
https://svn.apache.org/repos/asf/cxf/trunk

........
  r1345415 | dkulp | 2012-06-01 21:54:15 -0400 (Fri, 01 Jun 2012) | 1 line
  
  Start working toward getting ws-rm to be forkmode once
........

Added:
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java
      - copied, changed from r1345415, cxf/trunk/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractServerPersistenceTest.java
      - copied unchanged from r1345415, cxf/trunk/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractServerPersistenceTest.java
Modified:
    cxf/branches/2.5.x-fixes/   (props changed)
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutClientPersistenceTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutMessageTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutServerPersistenceTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ClientPersistenceTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ControlImpl.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledBareTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledClientServerTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ManagedEndpointsTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ProtocolVariationsTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionGZIPTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionQueueTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RobustServiceAtMostOnceTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServerPersistenceTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckBase.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckPersistenceTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAtMostOnceAckTest.java
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled.xml
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled_bare.xml
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent-message-loss-server.xml
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent.xml
    cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/sync-ack-persistent-server.xml

Propchange: cxf/branches/2.5.x-fixes/
------------------------------------------------------------------------------
Binary property 'svnmerge-integrated' - no diff available.

Copied: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java (from r1345415, cxf/trunk/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java)
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java?p2=cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java&p1=cxf/trunk/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java&r1=1345415&r2=1347053&rev=1347053&view=diff
==============================================================================
--- cxf/trunk/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/AbstractClientPersistenceTest.java Wed Jun  6 19:02:07 2012
@@ -47,6 +47,7 @@ import org.apache.cxf.testutil.recorders
 import org.apache.cxf.testutil.recorders.OutMessageRecorder;
 import org.apache.cxf.ws.addressing.VersionTransformer.Names200408;
 import org.apache.cxf.ws.rm.DestinationSequence;
+import org.apache.cxf.ws.rm.ProtocolVariation;
 import org.apache.cxf.ws.rm.RM10Constants;
 import org.apache.cxf.ws.rm.RMManager;
 import org.apache.cxf.ws.rm.RMUtils;
@@ -207,11 +208,11 @@ public abstract class AbstractClientPers
         String id = RMUtils.getEndpointIdentifier(client.getEndpoint());
         
         Collection<DestinationSequence> dss =
-            store.getDestinationSequences(id);
+            store.getDestinationSequences(id, ProtocolVariation.RM10WSA200408);
         assertEquals(1, dss.size());
         
         Collection<SourceSequence> sss =
-            store.getSourceSequences(id);
+            store.getSourceSequences(id, ProtocolVariation.RM10WSA200408);
         assertEquals(1, sss.size());
         
         Collection<RMMessage> msgs = 
@@ -294,11 +295,11 @@ public abstract class AbstractClientPers
         String id = RMUtils.getEndpointIdentifier(client.getEndpoint());
         
         Collection<DestinationSequence> dss =
-            store.getDestinationSequences(id);
+            store.getDestinationSequences(id, ProtocolVariation.RM10WSA200408);
         assertEquals(1, dss.size());
         
         Collection<SourceSequence> sss =
-            store.getSourceSequences(id);
+            store.getSourceSequences(id, ProtocolVariation.RM10WSA200408);
         assertEquals(1, sss.size());
         
         int i = 0;

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutClientPersistenceTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutClientPersistenceTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutClientPersistenceTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutClientPersistenceTest.java Wed Jun  6 19:02:07 2012
@@ -19,6 +19,9 @@
 
 package org.apache.cxf.systest.ws.rm;
 
+import org.apache.cxf.io.CachedOutputStream;
+import org.apache.cxf.ws.rm.persistence.jdbc.RMTxStore;
+
 import org.junit.AfterClass;
 import org.junit.BeforeClass;
 import org.junit.Test;
@@ -26,24 +29,20 @@ import org.junit.Test;
 /**
  * A simulated-large message version of ClientPersistenceTest.
  */
-public class CachedOutClientPersistenceTest extends ClientPersistenceTest {
-
-    private static String oldThreshold;
+public class CachedOutClientPersistenceTest extends AbstractClientPersistenceTest {
+    private static final String PORT = allocatePort(CachedOutClientPersistenceTest.class);
     
     @BeforeClass
-    public static void setProperties() throws Exception {
-        oldThreshold = System.getProperty("org.apache.cxf.io.CachedOutputStream.Threshold");
-        // forces the CacheOutputStream to use temporary file caching
-        System.setProperty("org.apache.cxf.io.CachedOutputStream.Threshold", "16");
+    public static void startServers() throws Exception {
+        startServers(PORT, "cocpt");
+        CachedOutputStream.setDefaultThreshold(16);
     }
     
     @AfterClass
     public static void cleanup() throws Exception {
-        if (oldThreshold == null) {
-            System.clearProperty("org.apache.cxf.io.CachedOutputStream.Threshold");
-        } else {
-            System.setProperty("org.apache.cxf.io.CachedOutputStream.Threshold", oldThreshold);
-        }
+        CachedOutputStream.setDefaultThreshold(-1);
+        RMTxStore.deleteDatabaseFiles("cocpt-server", true);
+        RMTxStore.deleteDatabaseFiles("cocpt-client", true);
     }
     
     @Test 
@@ -51,4 +50,14 @@ public class CachedOutClientPersistenceT
         super.testRecovery();
     }
 
+    @Override
+    public String getPort() {
+        return PORT;
+    }
+
+    @Override
+    public String getPrefix() {
+        return "cocpt";
+    }
+
 }

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutMessageTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutMessageTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutMessageTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutMessageTest.java Wed Jun  6 19:02:07 2012
@@ -31,6 +31,7 @@ import org.apache.cxf.greeter_control.Gr
 import org.apache.cxf.greeter_control.GreeterService;
 import org.apache.cxf.interceptor.LoggingInInterceptor;
 import org.apache.cxf.interceptor.LoggingOutInterceptor;
+import org.apache.cxf.io.CachedOutputStream;
 import org.apache.cxf.systest.ws.util.ConnectionHelper;
 import org.apache.cxf.testutil.common.AbstractBusClientServerTestBase;
 import org.apache.cxf.testutil.common.AbstractBusTestServerBase;
@@ -47,19 +48,18 @@ public class CachedOutMessageTest extend
     public static final String PORT = allocatePort(Server.class);
     public static final String DECOUPLE_PORT = allocatePort("decoupled.port");
 
-    private static String oldThreshold;
-    
     private static final Logger LOG = LogUtils.getLogger(RetransmissionQueueTest.class);
     private Bus bus;
     
 
     
     public static class Server extends AbstractBusTestServerBase {
-      
+        Endpoint ep;
         protected void run()  {            
             SpringBusFactory bf = new SpringBusFactory();
             Bus bus = bf.createBus("/org/apache/cxf/systest/ws/rm/message-loss.xml");
             BusFactory.setDefaultBus(bus);
+            setBus(bus);
             LoggingInInterceptor in = new LoggingInInterceptor();
             bus.getInInterceptors().add(in);
             bus.getInFaultInterceptors().add(in);
@@ -70,42 +70,28 @@ public class CachedOutMessageTest extend
             GreeterImpl implementor = new GreeterImpl();
             String address = "http://localhost:" + PORT + "/SoapContext/GreeterPort";
             
-            Endpoint ep = Endpoint.create(implementor);
+            ep = Endpoint.create(implementor);
             ep.publish(address);
 
             LOG.info("Published greeter endpoint.");
         }
- 
-        public static void main(String[] args) {
-            try { 
-                Server s = new Server(); 
-                s.start();
-            } catch (Exception ex) {
-                ex.printStackTrace();
-                System.exit(-1);
-            } finally { 
-                System.out.println("done!");
-            }
+        
+        public void tearDown() {
+            ep.stop();
+            ep = null;
         }
     }
 
     @BeforeClass
     public static void startServers() throws Exception {
-        oldThreshold = System.getProperty("org.apache.cxf.io.CachedOutputStream.Threshold");
-        // forces the CacheOutputStream to use temporary file caching
-        System.setProperty("org.apache.cxf.io.CachedOutputStream.Threshold", "16");
-
+        CachedOutputStream.setDefaultThreshold(16);
         assertTrue("server did not launch correctly", 
                    launchServer(Server.class, true));
     }
 
     @AfterClass
     public static void cleanup() throws Exception {
-        if (oldThreshold == null) {
-            System.clearProperty("org.apache.cxf.io.CachedOutputStream.Threshold");
-        } else {
-            System.setProperty("org.apache.cxf.io.CachedOutputStream.Threshold", oldThreshold);
-        }
+        CachedOutputStream.setDefaultThreshold(-1);
     }
 
     @Test

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutServerPersistenceTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutServerPersistenceTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutServerPersistenceTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/CachedOutServerPersistenceTest.java Wed Jun  6 19:02:07 2012
@@ -19,6 +19,9 @@
 
 package org.apache.cxf.systest.ws.rm;
 
+import org.apache.cxf.io.CachedOutputStream;
+import org.apache.cxf.ws.rm.persistence.jdbc.RMTxStore;
+
 import org.junit.AfterClass;
 import org.junit.BeforeClass;
 import org.junit.Test;
@@ -26,24 +29,20 @@ import org.junit.Test;
 /**
  * A simulated-large message version of ServerPersistenceTest.
  */
-public class CachedOutServerPersistenceTest extends ServerPersistenceTest {
-
-    private static String oldThreshold;
-    
+public class CachedOutServerPersistenceTest extends AbstractServerPersistenceTest {
+    public static final String PORT = allocatePort(CachedOutServerPersistenceTest.PORT);
+   
     @BeforeClass
     public static void setProperties() throws Exception {
-        oldThreshold = System.getProperty("org.apache.cxf.io.CachedOutputStream.Threshold");
-        // forces the CacheOutputStream to use temporary file caching
-        System.setProperty("org.apache.cxf.io.CachedOutputStream.Threshold", "16");
+        startServers(PORT, "cospt");
+        CachedOutputStream.setDefaultThreshold(16);
     }
     
     @AfterClass
     public static void cleanup() throws Exception {
-        if (oldThreshold == null) {
-            System.clearProperty("org.apache.cxf.io.CachedOutputStream.Threshold");
-        } else {
-            System.setProperty("org.apache.cxf.io.CachedOutputStream.Threshold", oldThreshold);
-        }
+        CachedOutputStream.setDefaultThreshold(-1);
+        RMTxStore.deleteDatabaseFiles("cospt-recovery", true);
+        RMTxStore.deleteDatabaseFiles("cospt-server", true);
     }
 
     @Test 
@@ -51,4 +50,12 @@ public class CachedOutServerPersistenceT
         super.testRecovery();
     }
 
+    public String getPort() {
+        return PORT;
+    }
+
+    public String getPrefix() {
+        return "cospt";
+    }
+
 }

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ClientPersistenceTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ClientPersistenceTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ClientPersistenceTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ClientPersistenceTest.java Wed Jun  6 19:02:07 2012
@@ -19,41 +19,7 @@
 
 package org.apache.cxf.systest.ws.rm;
 
-import java.util.Collection;
-import java.util.HashMap;
-import java.util.Map;
-import java.util.logging.Logger;
-
-import javax.xml.ws.BindingProvider;
-import javax.xml.ws.Endpoint;
-
-import junit.framework.AssertionFailedError;
-
-import org.apache.cxf.Bus;
-import org.apache.cxf.BusFactory;
-import org.apache.cxf.bus.spring.SpringBusFactory;
-import org.apache.cxf.common.logging.LogUtils;
-import org.apache.cxf.endpoint.Client;
-import org.apache.cxf.frontend.ClientProxy;
-import org.apache.cxf.greeter_control.Greeter;
-import org.apache.cxf.greeter_control.GreeterService;
-import org.apache.cxf.interceptor.LoggingInInterceptor;
-import org.apache.cxf.interceptor.LoggingOutInterceptor;
-import org.apache.cxf.systest.ws.util.MessageFlow;
-import org.apache.cxf.testutil.common.AbstractBusClientServerTestBase;
-import org.apache.cxf.testutil.common.AbstractBusTestServerBase;
-import org.apache.cxf.testutil.recorders.InMessageRecorder;
-import org.apache.cxf.testutil.recorders.MessageRecorder;
-import org.apache.cxf.testutil.recorders.OutMessageRecorder;
-import org.apache.cxf.ws.addressing.VersionTransformer.Names200408;
-import org.apache.cxf.ws.rm.DestinationSequence;
-import org.apache.cxf.ws.rm.ProtocolVariation;
-import org.apache.cxf.ws.rm.RM10Constants;
-import org.apache.cxf.ws.rm.RMManager;
-import org.apache.cxf.ws.rm.RMUtils;
-import org.apache.cxf.ws.rm.SourceSequence;
-import org.apache.cxf.ws.rm.persistence.RMMessage;
-import org.apache.cxf.ws.rm.persistence.RMStore;
+import org.apache.cxf.io.CachedOutputStream;
 import org.apache.cxf.ws.rm.persistence.jdbc.RMTxStore;
 
 import org.junit.AfterClass;
@@ -64,272 +30,33 @@ import org.junit.Test;
  * Tests the addition of WS-RM properties to application messages and the
  * exchange of WS-RM protocol messages.
  */
-public class ClientPersistenceTest extends AbstractBusClientServerTestBase {
-    public static final String PORT = allocatePort(Server.class); 
-    public static final String GREETMEONEWAY_ACTION 
-        = "http://cxf.apache.org/greeter_control/Greeter/greetMeOneWayRequest";
-    public static final String GREETME_ACTION
-        = "http://cxf.apache.org/greeter_control/Greeter/greetMeRequest";
-    private static final Logger LOG = LogUtils.getLogger(ClientPersistenceTest.class);
+public class ClientPersistenceTest extends AbstractClientPersistenceTest {
+    private static final String PORT = allocatePort(ClientPersistenceTest.class);
     
-    private Greeter greeter;
-    private OutMessageRecorder out;
-    private InMessageRecorder in;
-
-    public static class Server extends AbstractBusTestServerBase {
-
-        protected void run() {
-            SpringBusFactory bf = new SpringBusFactory();
-            Bus bus = bf.createBus("/org/apache/cxf/systest/ws/rm/persistent.xml");
-            BusFactory.setDefaultBus(bus);
-            
-            LoggingInInterceptor logIn = new LoggingInInterceptor();
-            bus.getInInterceptors().add(logIn);
-            LoggingOutInterceptor logOut = new LoggingOutInterceptor();
-            bus.getOutFaultInterceptors().add(logOut);
-            bus.getOutFaultInterceptors().add(logOut);
-            
-            bus.getExtension(RMManager.class).getRMAssertion().getBaseRetransmissionInterval()
-                .setMilliseconds(new Long(60000));
-            
-            GreeterImpl implementor = new GreeterImpl();
-            String address = "http://localhost:" + PORT + "/SoapContext/GreeterPort";
-            Endpoint ep = Endpoint.create(implementor);
-            Map<String, Object> properties = new HashMap<String, Object>();
-            properties.put("schema-validation-enabled", Boolean.TRUE);
-            ep.setProperties(properties);
-            ep.publish(address);
-            LOG.info("Published greeter endpoint.");
-        }
-
-        public static void main(String[] args) {
-            try {
-                RMTxStore.deleteDatabaseFiles();
-                Server s = new Server();
-                s.start();
-            } catch (Exception ex) {
-                ex.printStackTrace();
-                System.exit(-1);
-            } finally {
-                System.out.println("done!");
-            }
-        }
-    }
-
     @BeforeClass
-    public static void startServers() throws Exception {        
-        RMTxStore.deleteDatabaseFiles(RMTxStore.DEFAULT_DATABASE_NAME, false);
-        String derbyHome = System.getProperty("derby.system.home");
-        try {
-            if (derbyHome == null) {
-                System.setProperty("derby.system.home", "derby-server");
-            } else {
-                System.setProperty("derby.system.home", derbyHome + "-server");                
-            }
-            assertTrue("server did not launch correctly", launchServer(Server.class));
-        } finally {
-            if (derbyHome == null) {
-                System.clearProperty("derby.system.home");
-            } else {
-                System.setProperty("derby.system.home", derbyHome);
-            }
-        }
-        RMTxStore.deleteDatabaseFiles();
+    public static void startServers() throws Exception {
+        startServers(PORT, "cpt");
     }
     
     @AfterClass
-    public static void tearDownOnce() {
-        RMTxStore.deleteDatabaseFiles(RMTxStore.DEFAULT_DATABASE_NAME, false);
+    public static void cleanup() throws Exception {
+        CachedOutputStream.setDefaultThreshold(-1);
+        RMTxStore.deleteDatabaseFiles("cpt-server", true);
+        RMTxStore.deleteDatabaseFiles("cpt-client", true);
     }
-
+   
     @Test 
     public void testRecovery() throws Exception {
-        startClient();
-        populateStore();
-        verifyStorePopulation();
-        stopClient();
-        startClient();
-        populateStoreAfterRestart();
-        recover();
-        verifyRecovery();
-    }
-    
-    void startClient() throws Exception {
-        LOG.fine("Creating greeter client");
-        SpringBusFactory bf = new SpringBusFactory();
-        bus = bf.createBus("/org/apache/cxf/systest/ws/rm/persistent.xml");
-        BusFactory.setDefaultBus(bus);
-
-        GreeterService gs = new GreeterService();
-        greeter = gs.getGreeterPort();
-        updateAddressPort(greeter, PORT);
-        ((BindingProvider)greeter).getRequestContext().put("schema-validation-enabled", Boolean.TRUE);
-        out = new OutMessageRecorder();
-        in = new InMessageRecorder();
-
-        bus.getOutInterceptors().add(out);
-        bus.getInInterceptors().add(in);
-    }
-
-    void populateStore() throws Exception {
-        
-        bus.getExtension(RMManager.class).getRMAssertion().getBaseRetransmissionInterval()
-            .setMilliseconds(new Long(60000));
-        bus.getOutInterceptors().add(new MessageLossSimulator());
-                
-        greeter.greetMeOneWay("one");
-        greeter.greetMeOneWay("two");
-        greeter.greetMeOneWay("three");
-        greeter.greetMeOneWay("four");
-
-        awaitMessages(5, 3);
-        
-        MessageFlow mf = new MessageFlow(out.getOutboundMessages(), in.getInboundMessages(),
-            Names200408.WSA_NAMESPACE_NAME, RM10Constants.NAMESPACE_URI);
-        
-        // sent create seq + 4 app messages and losing 2 app messages
-        mf.verifyMessages(5, true);
-        String[] expectedActions = new String[] {RM10Constants.CREATE_SEQUENCE_ACTION,
-                                                 GREETMEONEWAY_ACTION,
-                                                 GREETMEONEWAY_ACTION,
-                                                 GREETMEONEWAY_ACTION,
-                                                 GREETMEONEWAY_ACTION};
-        mf.verifyActions(expectedActions, true);
-        mf.verifyMessageNumbers(new String[] {null, "1", "2", "3", "4"}, true);
-        mf.verifyAcknowledgements(new boolean[5], true);
-
-        // as 2 messages being lost, received seq ack and 2 ack messages 
-        mf.verifyMessages(3, false);
-        expectedActions = new String[] {RM10Constants.CREATE_SEQUENCE_RESPONSE_ACTION,
-            RM10Constants.SEQUENCE_ACKNOWLEDGMENT_ACTION,
-            RM10Constants.SEQUENCE_ACKNOWLEDGMENT_ACTION};
-        mf.verifyActions(expectedActions, false);
-        mf.verifyAcknowledgements(new boolean[] {false, true, true}, false);        
-    }
-    
-    void verifyStorePopulation() {
-        
-        RMManager manager = bus.getExtension(RMManager.class);
-        assertNotNull(manager);
-        
-        RMStore store = manager.getStore();
-        assertNotNull(store);
-        
-        Client client = ClientProxy.getClient(greeter);
-        String id = RMUtils.getEndpointIdentifier(client.getEndpoint());
-        
-        Collection<DestinationSequence> dss =
-            store.getDestinationSequences(id, ProtocolVariation.RM10WSA200408);
-        assertEquals(1, dss.size());
-        
-        Collection<SourceSequence> sss =
-            store.getSourceSequences(id, ProtocolVariation.RM10WSA200408);
-        assertEquals(1, sss.size());
-        
-        Collection<RMMessage> msgs = 
-            store.getMessages(sss.iterator().next().getIdentifier(), true);
-        assertEquals(2, msgs.size());  
-        
-        msgs = 
-            store.getMessages(sss.iterator().next().getIdentifier(), false);
-        assertEquals(0, msgs.size());  
-    }
-    
-    void stopClient() {
-        // ClientProxy.getClient(greeter).destroy();
-        bus.shutdown(true);
+        super.testRecovery();
     }
-      
-    void populateStoreAfterRestart() throws Exception {
-        
-        bus.getExtension(RMManager.class).getRMAssertion().getBaseRetransmissionInterval()
-            .setMilliseconds(new Long(60000));
-
-        greeter.greetMeOneWay("five");
-
-        // force at least two outbound messages, since can't always count on three
-        awaitMessages(1, 2);
-        
-        MessageFlow mf = new MessageFlow(out.getOutboundMessages(), in.getInboundMessages(),
-            Names200408.WSA_NAMESPACE_NAME, RM10Constants.NAMESPACE_URI);
-        
-        // sent 1 app message and no create seq messag this time
-        mf.verifyMessages(1, true);
-        String[] expectedActions = new String[] {GREETMEONEWAY_ACTION};
-
-        mf.verifyActions(expectedActions, true);
-        mf.verifyMessageNumbers(new String[] {"5"}, true);
-        mf.verifyAcknowledgements(new boolean[1], true);
 
-        // need in-exact as it COULD be 3 acks on a slow machine
-        //normally it will ack 1,3,5 and then 1-5, but on a slow machine,
-        //I've seen 1,3,5, then 1-3,5, and then 1-5
-        mf.verifyMessages(2, false, false);
-
-        // we can't reliably predict how the three remaining messages are acknowledged
-//        expectedActions = new String[] {RM10Constants.SEQUENCE_ACKNOWLEDGMENT_ACTION,
-//            RM10Constants.SEQUENCE_ACKNOWLEDGMENT_ACTION,
-//            null};
-//        mf.verifyActions(expectedActions, false);
-//        mf.verifyAcknowledgements(new boolean[]{true, true, false}, false);
-        
-        // verify the final ack range to be complete
-        try {
-            mf.verifyAcknowledgementRange(1, 5);
-        } catch (AssertionFailedError er) {
-            //possibly only got the first 2 ranges when split in 3, lets 
-            //wait for the third and then recheck
-            awaitMessages(1, 3);
-            mf.reset(out.getOutboundMessages(), in.getInboundMessages());
-            mf.verifyAcknowledgementRange(1, 5);
-        }
+    @Override
+    public String getPort() {
+        return PORT;
     }
 
-    void recover() throws Exception {
-        
-        // do nothing - resends should happen in the background  
-       
-        Thread.sleep(5000);
-        LOG.info("Recovered messages should have been resent by now.");
- 
-    }
-    
-    void verifyRecovery() throws Exception {
-        
-        RMManager manager = bus.getExtension(RMManager.class);
-        assertNotNull(manager);
-        
-        RMStore store = manager.getStore();
-        assertNotNull(store);
-        
-        Client client = ClientProxy.getClient(greeter);
-        String id = RMUtils.getEndpointIdentifier(client.getEndpoint());
-        
-        Collection<DestinationSequence> dss =
-            store.getDestinationSequences(id, ProtocolVariation.RM10WSA200408);
-        assertEquals(1, dss.size());
-        
-        Collection<SourceSequence> sss =
-            store.getSourceSequences(id, ProtocolVariation.RM10WSA200408);
-        assertEquals(1, sss.size());
-        
-        int i = 0;
-        while (store.getMessages(sss.iterator().next().getIdentifier(), true).size() > 0 && i < 10) {
-            Thread.sleep(200);
-            i++;
-        }
-       
-        assertEquals(0, store.getMessages(sss.iterator().next().getIdentifier(), true).size());
-        assertEquals(0, store.getMessages(sss.iterator().next().getIdentifier(), false).size());        
-    }
-    
-    private void awaitMessages(int nExpectedOut, int nExpectedIn) {
-        awaitMessages(nExpectedOut, nExpectedIn, 20000);
-    }
-    
-    private void awaitMessages(int nExpectedOut, int nExpectedIn, int timeout) {
-        MessageRecorder mr = new MessageRecorder(out, in);
-        mr.awaitMessages(nExpectedOut, nExpectedIn, timeout);
+    @Override
+    public String getPrefix() {
+        return "cpt";
     }
-
 }

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ControlImpl.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ControlImpl.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ControlImpl.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ControlImpl.java Wed Jun  6 19:02:07 2012
@@ -53,37 +53,34 @@ import org.apache.cxf.interceptor.Loggin
 public class ControlImpl  extends org.apache.cxf.greeter_control.ControlImpl {
     
     private static final Logger LOG = LogUtils.getLogger(ControlImpl.class);
+    
+    String dbName = "rmdb";
+    public void setDbName(String s) {
+        dbName = s;
+    }
 
     @Override
     public boolean startGreeter(String cfgResource) {
-        String derbyHome = System.getProperty("derby.system.home"); 
-        try {
-            System.setProperty("derby.system.home", derbyHome + "-server");   
-            SpringBusFactory bf = new SpringBusFactory();
-            greeterBus = bf.createBus(cfgResource);
-            BusFactory.setDefaultBus(greeterBus);
-            LOG.info("Initialised bus " + greeterBus + " with cfg file resource: " + cfgResource);
-            LOG.fine("greeterBus inInterceptors: " + greeterBus.getInInterceptors());
-
-            LoggingInInterceptor logIn = new LoggingInInterceptor();
-            LoggingOutInterceptor logOut = new LoggingOutInterceptor();
-            greeterBus.getInInterceptors().add(logIn);
-            greeterBus.getOutInterceptors().add(logOut);
-            greeterBus.getOutFaultInterceptors().add(logOut);
-
-            if (cfgResource.indexOf("provider") == -1) {
-                endpoint = Endpoint.publish(address, implementor);
-                LOG.info("Published greeter endpoint.");
-            } else {
-                endpoint = Endpoint.publish(address, new GreeterProvider());
-                LOG.info("Published greeter provider.");
-            }
-        } finally {
-            if (derbyHome != null) {
-                System.setProperty("derby.system.home", derbyHome);
-            } else {
-                System.clearProperty("derby.system.home");
-            }
+        SpringBusFactory bf = new SpringBusFactory();
+        System.setProperty("db.name", dbName);
+        greeterBus = bf.createBus(cfgResource);
+        System.clearProperty("db.name");
+        BusFactory.setDefaultBus(greeterBus);
+        LOG.info("Initialised bus " + greeterBus + " with cfg file resource: " + cfgResource);
+        LOG.fine("greeterBus inInterceptors: " + greeterBus.getInInterceptors());
+
+        LoggingInInterceptor logIn = new LoggingInInterceptor();
+        LoggingOutInterceptor logOut = new LoggingOutInterceptor();
+        greeterBus.getInInterceptors().add(logIn);
+        greeterBus.getOutInterceptors().add(logOut);
+        greeterBus.getOutFaultInterceptors().add(logOut);
+
+        if (cfgResource.indexOf("provider") == -1) {
+            endpoint = Endpoint.publish(address, implementor);
+            LOG.info("Published greeter endpoint.");
+        } else {
+            endpoint = Endpoint.publish(address, new GreeterProvider());
+            LOG.info("Published greeter provider.");
         }
         
         return true;        

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledBareTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledBareTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledBareTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledBareTest.java Wed Jun  6 19:02:07 2012
@@ -48,44 +48,37 @@ import org.junit.Test;
  */
 public class DecoupledBareTest extends AbstractBusClientServerTestBase {
     public static final String PORT = allocatePort(Server.class);
-    public static final String DECOUPLE_PORT = allocatePort("decoupled.port");
+    public static final String DECOUPLE_PORT = allocatePort(DecoupledBareTest.class);
     
     private static final Logger LOG = LogUtils.getLogger(DecoupledBareTest.class);
 
     public static class Server extends AbstractBusTestServerBase {
         
+        Endpoint ep;
         protected void run()  {            
             SpringBusFactory bf = new SpringBusFactory();
             Bus bus = bf.createBus("/org/apache/cxf/systest/ws/rm/decoupled_bare.xml");
             BusFactory.setDefaultBus(bus);
+            setBus(bus);
             
             Object implementor = new DocLitBareGreeterImpl();
             String address = "http://localhost:" + PORT + "/SoapContext/SoapPort";
-            Endpoint ep = Endpoint.create(implementor);
+            ep = Endpoint.create(implementor);
             Map<String, Object> properties = new HashMap<String, Object>();
             properties.put("schema-validation-enabled", Boolean.TRUE);
             ep.setProperties(properties);
             ep.publish(address);
             LOG.info("Published server endpoint.");
         }
-        
-
-        public static void main(String[] args) {
-            try { 
-                Server s = new Server(); 
-                s.start();
-            } catch (Exception ex) {
-                ex.printStackTrace();
-                System.exit(-1);
-            } finally { 
-                System.out.println("done!");
-            }
+        public void tearDown() {
+            ep.stop();
+            ep = null;
         }
     }    
     
     @BeforeClass
     public static void startServers() throws Exception {
-        assertTrue("server did not launch correctly", launchServer(Server.class));
+        assertTrue("server did not launch correctly", launchServer(Server.class, true));
     }
     
     @Test

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledClientServerTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledClientServerTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledClientServerTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/DecoupledClientServerTest.java Wed Jun  6 19:02:07 2012
@@ -47,17 +47,18 @@ import org.junit.Test;
  */
 public class DecoupledClientServerTest extends AbstractBusClientServerTestBase {
     public static final String PORT = allocatePort(Server.class);
-    public static final String DECOUPLE_PORT = allocatePort("decoupled.port");
+    public static final String DECOUPLE_PORT = allocatePort(DecoupledClientServerTest.class);
 
     private static final Logger LOG = LogUtils.getLogger(DecoupledClientServerTest.class);
     private Bus bus;
 
     public static class Server extends AbstractBusTestServerBase {
-        
+        Endpoint ep;
         protected void run()  {            
             SpringBusFactory bf = new SpringBusFactory();
             Bus bus = bf.createBus("/org/apache/cxf/systest/ws/rm/decoupled.xml");
             BusFactory.setDefaultBus(bus);
+            setBus(bus);
             LoggingInInterceptor in = new LoggingInInterceptor();
             bus.getInInterceptors().add(in);
             bus.getInFaultInterceptors().add(in);
@@ -70,7 +71,7 @@ public class DecoupledClientServerTest e
             implementor.setDelay(5000);
             String address = "http://localhost:" + PORT + "/SoapContext/GreeterPort";
             
-            Endpoint ep = Endpoint.create(implementor);
+            ep = Endpoint.create(implementor);
             Map<String, Object> properties = new HashMap<String, Object>();
             properties.put("schema-validation-enabled",
                            shouldValidate());
@@ -79,25 +80,16 @@ public class DecoupledClientServerTest e
 
             LOG.info("Published greeter endpoint.");
         }
-        
-
-        public static void main(String[] args) {
-            try { 
-                Server s = new Server(); 
-                s.start();
-            } catch (Exception ex) {
-                ex.printStackTrace();
-                System.exit(-1);
-            } finally { 
-                System.out.println("done!");
-            }
+        public void tearDown() {
+            ep.stop();
+            ep = null;
         }
     }    
     
     @BeforeClass
     public static void startServers() throws Exception {
         assertTrue("server did not launch correctly", 
-                   launchServer(Server.class));
+                   launchServer(Server.class, true));
     }
             
     public static Boolean shouldValidate() {

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ManagedEndpointsTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ManagedEndpointsTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ManagedEndpointsTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ManagedEndpointsTest.java Wed Jun  6 19:02:07 2012
@@ -48,8 +48,7 @@ import org.junit.Test;
  * 
  */
 public class ManagedEndpointsTest extends AbstractClientServerTestBase {
-    public static final String PORT = allocatePort(Server.class);
-//    public static final String DECOUPLE_PORT = allocatePort("decoupled.port");
+    public static final String PORT = allocatePort(ManagedEndpointsTest.class);
 
     private static final String SERVER_CFG = "/org/apache/cxf/systest/ws/rm/managed-server.xml"; 
     private static final String CLIENT_CFG = "/org/apache/cxf/systest/ws/rm/managed-client.xml"; 

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ProtocolVariationsTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ProtocolVariationsTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ProtocolVariationsTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ProtocolVariationsTest.java Wed Jun  6 19:02:07 2012
@@ -24,6 +24,7 @@ import java.util.logging.Logger;
 
 import javax.xml.transform.dom.DOMSource;
 import javax.xml.ws.Dispatch;
+import javax.xml.ws.Endpoint;
 
 import org.apache.cxf.Bus;
 import org.apache.cxf.BusFactory;
@@ -38,8 +39,8 @@ import org.apache.cxf.greeter_control.Gr
 import org.apache.cxf.jaxws.DispatchImpl;
 import org.apache.cxf.systest.ws.util.ConnectionHelper;
 import org.apache.cxf.systest.ws.util.MessageFlow;
-import org.apache.cxf.test.TestUtilities;
 import org.apache.cxf.testutil.common.AbstractBusClientServerTestBase;
+import org.apache.cxf.testutil.common.AbstractBusTestServerBase;
 import org.apache.cxf.testutil.recorders.InMessageRecorder;
 import org.apache.cxf.testutil.recorders.MessageRecorder;
 import org.apache.cxf.testutil.recorders.OutMessageRecorder;
@@ -54,7 +55,6 @@ import org.apache.cxf.ws.rm.RMException;
 import org.apache.cxf.ws.rm.RMManager;
 
 import org.junit.After;
-import org.junit.AfterClass;
 import org.junit.BeforeClass;
 import org.junit.Test;
 
@@ -63,7 +63,7 @@ import org.junit.Test;
  * variation is used by the client.
  */
 public class ProtocolVariationsTest extends AbstractBusClientServerTestBase {
-    public static final String PORT = Server.PORT;
+    public static final String PORT = allocatePort(ProtocolVariationsTest.class);
 
     private static final Logger LOG = LogUtils.getLogger(ProtocolVariationsTest.class);
     private static final String GREETME_ACTION
@@ -81,17 +81,36 @@ public class ProtocolVariationsTest exte
     private InMessageRecorder inRecorder;
     private Dispatch<DOMSource> dispatch;
 
+    public static class Server extends AbstractBusTestServerBase {
+        Endpoint ep;
+        
+        protected void run() {
+            SpringBusFactory factory = new SpringBusFactory();
+            Bus bus = factory.createBus();
+            BusFactory.setDefaultBus(bus);
+            setBus(bus);
+
+            //System.out.println("Created control bus " + bus);
+            ControlImpl implementor = new ControlImpl();
+            implementor.setDbName("pvt-server");
+            implementor.setAddress("http://localhost:" + PORT + "/SoapContext/GreeterPort");
+            GreeterImpl greeterImplementor = new GreeterImpl();
+            implementor.setImplementor(greeterImplementor);
+            ep = Endpoint.publish("http://localhost:" + PORT + "/SoapContext/ControlPort", implementor);
+            BusFactory.setDefaultBus(null);
+            BusFactory.setThreadDefaultBus(null); 
+        }
+        public void tearDown() {
+            ep.stop();
+            ep = null;
+        }
+    }
 
     @BeforeClass
     public static void startServers() throws Exception {
-        TestUtilities.setKeepAliveSystemProperty(false);
-        assertTrue("server did not launch correctly", launchServer(Server.class));
-    }
-    
-    @AfterClass
-    public static void cleanup() {
-        TestUtilities.recoverKeepAliveSystemProperty();
+        assertTrue("server did not launch correctly", launchServer(Server.class, true));
     }
+
             
     
     @After

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionGZIPTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionGZIPTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionGZIPTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionGZIPTest.java Wed Jun  6 19:02:07 2012
@@ -51,7 +51,7 @@ import org.junit.Test;
  */
 public class RetransmissionGZIPTest extends AbstractBusClientServerTestBase {
     public static final String PORT = allocatePort(Server.class);
-    public static final String DECOUPLE_PORT = allocatePort("decoupled.port");
+    public static final String DECOUPLE_PORT = allocatePort(RetransmissionGZIPTest.class);
 
     private static final Logger LOG = LogUtils.getLogger(RetransmissionQueueTest.class);
     private Bus bus;

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionQueueTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionQueueTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionQueueTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RetransmissionQueueTest.java Wed Jun  6 19:02:07 2012
@@ -44,7 +44,7 @@ import org.junit.Test;
  */
 public class RetransmissionQueueTest extends AbstractBusClientServerTestBase {
     public static final String PORT = allocatePort(Server.class);
-    public static final String DECOUPLE_PORT = allocatePort("decoupled.port");
+    public static final String DECOUPLE_PORT = allocatePort(RetransmissionQueueTest.class);
 
     private static final Logger LOG = LogUtils.getLogger(RetransmissionQueueTest.class);
     private Bus bus;

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RobustServiceAtMostOnceTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RobustServiceAtMostOnceTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RobustServiceAtMostOnceTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/RobustServiceAtMostOnceTest.java Wed Jun  6 19:02:07 2012
@@ -52,12 +52,13 @@ public class RobustServiceAtMostOnceTest
 
     
     public static class Server extends AbstractBusTestServerBase {
-
+        Endpoint ep;
         protected void run() {
             SpringBusFactory bf = new SpringBusFactory();
             // use a at-most-once server with sync ack processing
             Bus bus = bf.createBus("/org/apache/cxf/systest/ws/rm/atmostonce.xml");
             BusFactory.setDefaultBus(bus);
+            setBus(bus);
             bus.getExtension(RMManager.class).getRMAssertion().getAcknowledgementInterval()
                 .setMilliseconds(0L);
 
@@ -70,23 +71,16 @@ public class RobustServiceAtMostOnceTest
             String address = "http://localhost:" + PORT + "/SoapContext/GreeterPort";
             
             // publish this robust oneway endpoint
-            Endpoint ep = Endpoint.create(serverGreeter);
+            ep = Endpoint.create(serverGreeter);
             ep.getProperties().put(Message.ROBUST_ONEWAY, Boolean.TRUE);
             ep.publish(address);
             LOG.info("Published greeter endpoint.");
         }
-
-        public static void main(String[] args) {
-            try {
-                Server s = new Server();
-                s.start();
-            } catch (Exception ex) {
-                ex.printStackTrace();
-                System.exit(-1);
-            } finally {
-                System.out.println("done!");
-            }
+        public void tearDown() {
+            ep.stop();
+            ep = null;
         }
+
     }
 
     @BeforeClass

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServerPersistenceTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServerPersistenceTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServerPersistenceTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServerPersistenceTest.java Wed Jun  6 19:02:07 2012
@@ -19,254 +19,35 @@
 
 package org.apache.cxf.systest.ws.rm;
 
-import java.util.logging.Logger;
 
-import javax.xml.ws.Response;
-
-import org.apache.cxf.Bus;
-import org.apache.cxf.BusFactory;
-import org.apache.cxf.bus.spring.SpringBusFactory;
-import org.apache.cxf.common.logging.LogUtils;
-import org.apache.cxf.endpoint.Client;
-import org.apache.cxf.frontend.ClientProxy;
-import org.apache.cxf.greeter_control.Control;
-import org.apache.cxf.greeter_control.ControlService;
-import org.apache.cxf.greeter_control.Greeter;
-import org.apache.cxf.greeter_control.GreeterService;
-import org.apache.cxf.greeter_control.types.GreetMeResponse;
-import org.apache.cxf.systest.ws.util.ConnectionHelper;
-import org.apache.cxf.systest.ws.util.MessageFlow;
-import org.apache.cxf.testutil.common.AbstractBusClientServerTestBase;
-import org.apache.cxf.testutil.recorders.InMessageRecorder;
-import org.apache.cxf.testutil.recorders.MessageRecorder;
-import org.apache.cxf.testutil.recorders.OutMessageRecorder;
-import org.apache.cxf.transport.http.HTTPConduit;
-import org.apache.cxf.transports.http.configuration.HTTPClientPolicy;
-import org.apache.cxf.ws.addressing.VersionTransformer.Names200408;
-import org.apache.cxf.ws.rm.RM10Constants;
-import org.apache.cxf.ws.rm.RMManager;
 import org.apache.cxf.ws.rm.persistence.jdbc.RMTxStore;
 
+import org.junit.AfterClass;
 import org.junit.BeforeClass;
-import org.junit.Test;
 
 /**
  * Tests the addition of WS-RM properties to application messages and the
  * exchange of WS-RM protocol messages.
  */
-public class ServerPersistenceTest extends AbstractBusClientServerTestBase {
-    public static final String PORT = Server.PORT;
-    public static final String DECOUPLE_PORT = allocatePort("decoupled.port");
-
-    public static final String GREETMEONEWAY_ACTION 
-        = "http://cxf.apache.org/greeter_control/Greeter/greetMeOneWayRequest";
-    public static final String GREETME_ACTION
-        = "http://cxf.apache.org/greeter_control/Greeter/greetMeRequest";
-    private static final String GREETME_RESPONSE_ACTION
-        = "http://cxf.apache.org/greeter_control/Greeter/greetMeResponse";
-
-    private static final Logger LOG = LogUtils.getLogger(ServerPersistenceTest.class);
-    private static final String CFG = "/org/apache/cxf/systest/ws/rm/persistent.xml";
-    private static final String SERVER_LOSS_CFG 
-        = "/org/apache/cxf/systest/ws/rm/persistent-message-loss-server.xml";
-
-    private OutMessageRecorder out;
-    private InMessageRecorder in;
-    private Bus greeterBus;
+public class ServerPersistenceTest extends AbstractServerPersistenceTest {
+    public static final String PORT = allocatePort(ServerPersistenceTest.PORT);
     
+    public String getPort() {
+        return PORT;
+    }
     @BeforeClass
     public static void startServers() throws Exception {
-        String derbyHome = System.getProperty("derby.system.home");
-        if (derbyHome == null) {
-            System.setProperty("derby.system.home", "target/derby");
-        }
-        RMTxStore.deleteDatabaseFiles();
-        derbyHome = System.getProperty("derby.system.home"); 
-        try {
-            System.setProperty("derby.system.home", derbyHome + "-server");
-            RMTxStore.deleteDatabaseFiles();
-        } finally {
-            if (derbyHome != null) {
-                System.setProperty("derby.system.home", derbyHome);
-            } else {
-                System.clearProperty("derby.system.home");
-            }
-        }
-        assertTrue("server did not launch correctly", launchServer(Server.class));  
-    }
-    
-    @Test 
-    public void testRecovery() throws Exception {
-        SpringBusFactory bf = new SpringBusFactory();
-        bus = bf.createBus();
-        BusFactory.setDefaultBus(bus);        
-        LOG.fine("Created bus " + bus + " with default cfg");
-        ControlService cs = new ControlService();
-        Control control = cs.getControlPort();
-        ConnectionHelper.setKeepAliveConnection(control, false, true);
-        updateAddressPort(control, PORT);
-        
-        assertTrue("Failed to start greeter", control.startGreeter(SERVER_LOSS_CFG)); 
-        LOG.fine("Started greeter server.");
-        
-        greeterBus = new SpringBusFactory().createBus(CFG);
-        LOG.fine("Created bus " + greeterBus + " with cfg : " + CFG);        
-        BusFactory.setDefaultBus(greeterBus);
-        
-        // avoid early client resends
-        greeterBus.getExtension(RMManager.class).getRMAssertion().getBaseRetransmissionInterval()
-            .setMilliseconds(new Long(60000));
-        GreeterService gs = new GreeterService();
-        Greeter greeter = gs.getGreeterPort();
-        updateAddressPort(greeter, PORT);
-        
-        LOG.fine("Created greeter client.");
- 
-        ConnectionHelper.setKeepAliveConnection(greeter, false, true);
-
-        Client c = ClientProxy.getClient(greeter);
-        HTTPConduit hc = (HTTPConduit)(c.getConduit());
-        HTTPClientPolicy cp = hc.getClient();
-        cp.setDecoupledEndpoint("http://localhost:" + DECOUPLE_PORT + "/decoupled_endpoint");
-
-        out = new OutMessageRecorder();
-        in = new InMessageRecorder();
-
-        greeterBus.getOutInterceptors().add(out);
-        greeterBus.getInInterceptors().add(in);
-        
-        LOG.fine("Configured greeter client.");
-
-        Response<GreetMeResponse> responses[] = cast(new Response[4]);
-        
-        responses[0] = greeter.greetMeAsync("one");
-        responses[1] = greeter.greetMeAsync("two");
-        responses[2] = greeter.greetMeAsync("three");
-        
-        verifyMissingResponse(responses);
-        control.stopGreeter(SERVER_LOSS_CFG);
-        LOG.fine("Stopped greeter server");
-       
-        out.getOutboundMessages().clear();
-        in.getInboundMessages().clear();
-        
-        control.startGreeter(CFG);
-        String nl = System.getProperty("line.separator");
-        LOG.fine("Restarted greeter server" + nl + nl);
-        
-        verifyServerRecovery(responses);
-        responses[3] = greeter.greetMeAsync("four");
-        
-        verifyRetransmissionQueue();
-        verifyAcknowledgementRange(1, 4);
-        
-        out.getOutboundMessages().clear();
-        in.getInboundMessages().clear();
-
-        greeterBus.shutdown(true);
-        
-        control.stopGreeter(CFG);
-        bus.shutdown(true);
-    }
-    
-    void verifyMissingResponse(Response<GreetMeResponse> responses[]) throws Exception {
-        awaitMessages(5, 3, 25000);
-
-        int nDone = 0;
-        for (int i = 0; i < 3; i++) {
-            if (responses[i].isDone()) {
-                nDone++;
-            }
-        }
-        
-        assertEquals("Unexpected number of responses already received.", 2, nDone);
-        
-        MessageFlow mf = new MessageFlow(out.getOutboundMessages(), in.getInboundMessages(),
-            Names200408.WSA_NAMESPACE_NAME, RM10Constants.NAMESPACE_URI);
-        String[] expectedActions = new String[] {RM10Constants.CREATE_SEQUENCE_ACTION,
-                                                 GREETME_ACTION,
-                                                 GREETME_ACTION,
-                                                 GREETME_ACTION,
-                                                 RM10Constants.SEQUENCE_ACKNOWLEDGMENT_ACTION};
-        mf.verifyActions(expectedActions, true);
-        // mf.verifyMessageNumbers(new String[] {null, "1", "2", "3"}, true);
-        // mf.verifyAcknowledgements(new boolean[] {false, false, true, false}, true);
-        
-//        mf.verifyPartialResponses(5);
-//        mf.purgePartialResponses();
-        expectedActions = new String[] {RM10Constants.CREATE_SEQUENCE_RESPONSE_ACTION,
-                                        GREETME_RESPONSE_ACTION,
-                                        GREETME_RESPONSE_ACTION};
-        mf.verifyActions(expectedActions, false);
-        // mf.verifyMessageNumbers(new String[] {null, "1", "3"}, false);
-        // mf.verifyAcknowledgements(new boolean[] {false, true, true}, false);    
-    }
-    
-    void verifyServerRecovery(Response<GreetMeResponse> responses[]) throws Exception {
-   
-        // wait until all messages have received their responses
-        int nDone = 0;
-        long waited = 0;
-        while (waited < 30) {
-            nDone = 0;
-            for (int i = 0; i < responses.length - 1; i++) {
-                if (responses[i].isDone()) {
-                    nDone++;
-                }
-            }
-            if (nDone == 3) {
-                break;
-            }
-            Thread.sleep(500);
-            waited++;
-        }
-        
-        assertEquals("Not all responses have been received.", 3, nDone);
-
-        // verify that all inbound messages are resent responses
-        
-        synchronized (this) {
-            MessageFlow mf = new MessageFlow(out.getOutboundMessages(), in.getInboundMessages(),
-                Names200408.WSA_NAMESPACE_NAME, RM10Constants.NAMESPACE_URI);
-            int nOut = out.getOutboundMessages().size();
-            int nIn = in.getInboundMessages().size();
-            assertEquals("Unexpected outbound message(s)", 0, nOut);
-            assertTrue(nIn >= 1);
-            String[] expectedActions = new String[nIn];
-            for (int i = 0; i < nIn; i++) {
-                expectedActions[i] = GREETME_RESPONSE_ACTION;
-            }
-            mf.verifyActions(expectedActions, false);
-        }
-    }
-  
-    
-    void verifyRetransmissionQueue() throws Exception {
-        awaitMessages(2, 3, 60000);
-        
-        Thread.sleep(5000);
-        boolean empty = greeterBus.getExtension(RMManager.class).getRetransmissionQueue().isEmpty();
-        assertTrue("Retransmission Queue is not empty", empty);
-    }
-    
-    void verifyAcknowledgementRange(long lower, long higher) throws Exception {
-        MessageFlow mf = new MessageFlow(out.getOutboundMessages(), in.getInboundMessages(),
-            Names200408.WSA_NAMESPACE_NAME, RM10Constants.NAMESPACE_URI);
-        mf.verifyAcknowledgementRange(lower, higher);
-    }
-
-    protected void awaitMessages(int nExpectedOut, int nExpectedIn) {
-        awaitMessages(nExpectedOut, nExpectedIn, 20000);
+        startServers(PORT, "spt");
     }
     
-    private void awaitMessages(int nExpectedOut, int nExpectedIn, int timeout) {
-        MessageRecorder mr = new MessageRecorder(out, in);
-        mr.awaitMessages(nExpectedOut, nExpectedIn, timeout);
+    @AfterClass
+    public static void cleanup() throws Exception {
+        RMTxStore.deleteDatabaseFiles("spt-recovery", true);
+        RMTxStore.deleteDatabaseFiles("spt-rmdb", true);
     }
     
-    @SuppressWarnings("unchecked")
-    <T> Response<T>[] cast(Response<?>[] val) {
-        return (Response<T>[])val;
+    public String getPrefix() {
+        return "spt";
     }
 
 }

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckBase.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckBase.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckBase.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckBase.java Wed Jun  6 19:02:07 2012
@@ -34,15 +34,12 @@ import org.apache.cxf.greeter_control.Gr
 import org.apache.cxf.greeter_control.types.FaultLocation;
 import org.apache.cxf.interceptor.ServiceInvokerInterceptor;
 import org.apache.cxf.phase.Phase;
-import org.apache.cxf.test.TestUtilities;
 import org.apache.cxf.testutil.common.AbstractBusClientServerTestBase;
 import org.apache.cxf.testutil.common.AbstractBusTestServerBase;
 import org.apache.cxf.ws.rm.RMManager;
 import org.apache.cxf.ws.rm.RetransmissionQueue;
 
 import org.junit.After;
-import org.junit.AfterClass;
-import org.junit.BeforeClass;
 import org.junit.Test;
 
 /**
@@ -50,15 +47,14 @@ import org.junit.Test;
  * error at the provider side and how its behavior is affected by the robust in-only mode setting.
  */
 public abstract class ServiceInvocationAckBase extends AbstractBusClientServerTestBase {
-    public static final String PORT = allocatePort(Server.class);
-    
     private static final Logger LOG = LogUtils.getLogger(ServiceInvocationAckBase.class);
 
-    private static final String CONTROL_PORT_ADDRESS = 
-        "http://localhost:" + PORT + "/SoapContext/ControlPort";
-
     public static class Server extends AbstractBusTestServerBase {
-
+        String port;
+        Endpoint ep;
+        public Server(String args[]) {
+            port = args[0];
+        }
         protected void run() {
             SpringBusFactory factory = new SpringBusFactory();
             Bus bus = factory.createBus();
@@ -66,23 +62,15 @@ public abstract class ServiceInvocationA
             setBus(bus);
 
             ControlImpl implementor = new ControlImpl();
-            implementor.setAddress("http://localhost:" + PORT + "/SoapContext/GreeterPort");
+            implementor.setAddress("http://localhost:" + port + "/SoapContext/GreeterPort");
             GreeterImpl greeterImplementor = new GreeterImpl();
             implementor.setImplementor(greeterImplementor);
-            Endpoint.publish(CONTROL_PORT_ADDRESS, implementor);
+            ep = Endpoint.publish("http://localhost:" + port + "/SoapContext/ControlPort", implementor);
             LOG.fine("Published control endpoint.");
         }
-
-        public static void main(String[] args) {
-            try {
-                Server s = new Server();
-                s.start();
-            } catch (Exception ex) {
-                ex.printStackTrace();
-                System.exit(-1);
-            } finally {
-                System.out.println("done!");
-            }
+        public void tearDown() {
+            ep.stop();
+            ep = null;
         }
     }
     
@@ -91,17 +79,13 @@ public abstract class ServiceInvocationA
     private Bus greeterBus;
     private Greeter greeter;
     
+    public abstract String getPort();
 
-    @BeforeClass
-    public static void startServers() throws Exception {
-        TestUtilities.setKeepAliveSystemProperty(false);
-        assertTrue("server did not launch correctly", launchServer(Server.class, true));
+    public static void startServer(String port) throws Exception {
+        assertTrue("server did not launch correctly", 
+                   launchServer(Server.class, null, new String[] {port}, true));
     }
     
-    @AfterClass
-    public static void cleanup() {
-        TestUtilities.recoverKeepAliveSystemProperty();
-    }
     
     @After
     public void tearDown() {
@@ -214,7 +198,7 @@ public abstract class ServiceInvocationA
 
         ControlService cs = new ControlService();
         control = cs.getControlPort();
-        updateAddressPort(control, PORT);
+        updateAddressPort(control, getPort());
         
         assertTrue("Failed to start greeter", control.startGreeter(cfgResource));
         
@@ -225,8 +209,10 @@ public abstract class ServiceInvocationA
         GreeterService gs = new GreeterService();
 
         greeter = gs.getGreeterPort();
-        updateAddressPort(greeter, PORT);
+        updateAddressPort(greeter, getPort());
         LOG.fine("Created greeter client.");
 
     }
+
+
 }

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckPersistenceTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckPersistenceTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckPersistenceTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckPersistenceTest.java Wed Jun  6 19:02:07 2012
@@ -20,6 +20,7 @@ package org.apache.cxf.systest.ws.rm;
 
 import org.apache.cxf.ws.rm.persistence.jdbc.RMTxStore;
 
+import org.junit.AfterClass;
 import org.junit.BeforeClass;
 
 /**
@@ -27,24 +28,19 @@ import org.junit.BeforeClass;
  * error at the provider side and how its behavior is affected by the robust in-only mode setting.
  */
 public class ServiceInvocationAckPersistenceTest extends ServiceInvocationAckBase {
+    static final String PORT = allocatePort(ServiceInvocationAckPersistenceTest.class);
+    
     @BeforeClass
+    public static void startServers() throws Exception {
+        RMTxStore.deleteDatabaseFiles("synack", true);
+        startServer(PORT);
+    }
+    public String getPort() {
+        return PORT;
+    }
+    @AfterClass
     public static void cleanUpDerby() throws Exception {
-        String derbyHome = System.getProperty("derby.system.home");
-        if (derbyHome == null) {
-            System.setProperty("derby.system.home", "target/derby");
-        }
-        RMTxStore.deleteDatabaseFiles();
-        derbyHome = System.getProperty("derby.system.home"); 
-        try {
-            System.setProperty("derby.system.home", derbyHome + "-server");
-            RMTxStore.deleteDatabaseFiles();
-        } finally {
-            if (derbyHome != null) {
-                System.setProperty("derby.system.home", derbyHome);
-            } else {
-                System.clearProperty("derby.system.home");
-            }
-        }
+        RMTxStore.deleteDatabaseFiles("synack", true);
     }
 
     protected void setupGreeter() throws Exception {

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAckTest.java Wed Jun  6 19:02:07 2012
@@ -18,11 +18,24 @@
  */
 package org.apache.cxf.systest.ws.rm;
 
+import org.junit.BeforeClass;
+
 /**
  * Tests the acknowledgement delivery back to the non-decoupled port when there is some
  * error at the provider side and how its behavior is affected by the robust in-only mode setting.
  */
 public class ServiceInvocationAckTest extends ServiceInvocationAckBase {
+    static final String PORT = allocatePort(ServiceInvocationAckTest.class);
+    
+    @BeforeClass
+    public static void startServers() throws Exception {
+        startServer(PORT);
+    }
+    public String getPort() {
+        return PORT;
+    }
+
+    
     protected void setupGreeter() throws Exception {
         setupGreeter("org/apache/cxf/systest/ws/rm/sync-ack-server.xml");
     }

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAtMostOnceAckTest.java
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAtMostOnceAckTest.java?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAtMostOnceAckTest.java (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/ServiceInvocationAtMostOnceAckTest.java Wed Jun  6 19:02:07 2012
@@ -18,11 +18,22 @@
  */
 package org.apache.cxf.systest.ws.rm;
 
+import org.junit.BeforeClass;
+
 /**
  * Tests the acknowledgement delivery back to the non-decoupled port when there is some
  * error at the provider side and how its behavior is affected by the robust in-only mode setting.
  */
 public class ServiceInvocationAtMostOnceAckTest extends ServiceInvocationAckBase {
+    static final String PORT = allocatePort(ServiceInvocationAtMostOnceAckTest.class);
+    
+    @BeforeClass
+    public static void startServers() throws Exception {
+        startServer(PORT);
+    }
+    public String getPort() {
+        return PORT;
+    }
     protected void setupGreeter() throws Exception {
         setupGreeter("org/apache/cxf/systest/ws/rm/sync-ack-atmostonce-server.xml");
     }

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled.xml
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled.xml?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled.xml (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled.xml Wed Jun  6 19:02:07 2012
@@ -28,7 +28,7 @@ http://www.springframework.org/schema/be
     <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/>
   
     <http:conduit name="{http://cxf.apache.org/greeter_control}GreeterPort.http-conduit">
-      <http:client DecoupledEndpoint="http://localhost:${testutil.ports.decoupled.port}/decoupled_endpoint"/>
+      <http:client DecoupledEndpoint="http://localhost:${testutil.ports.DecoupledClientServerTest}/decoupled_endpoint"/>
     </http:conduit>
     
     <bean id="mapAggregator" class="org.apache.cxf.ws.addressing.MAPAggregator"/>

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled_bare.xml
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled_bare.xml?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled_bare.xml (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/decoupled_bare.xml Wed Jun  6 19:02:07 2012
@@ -28,7 +28,7 @@ http://www.springframework.org/schema/be
     <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/>
   
     <http:conduit name="{http://apache.org/hello_world_soap_http}SoapPort.http-conduit">
-      <http:client DecoupledEndpoint="http://localhost:${testutil.ports.decoupled.port}/decoupled_endpoint"/>
+      <http:client DecoupledEndpoint="http://localhost:${testutil.ports.DecoupledBareTest}/decoupled_endpoint"/>
     </http:conduit>
     
     <bean id="mapAggregator" class="org.apache.cxf.ws.addressing.MAPAggregator"/>

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent-message-loss-server.xml
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent-message-loss-server.xml?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent-message-loss-server.xml (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent-message-loss-server.xml Wed Jun  6 19:02:07 2012
@@ -32,6 +32,8 @@ http://cxf.apache.org/ws/rm/manager http
 http://cxf.apache.org/configuration/beans http://cxf.apache.org/schemas/configuration/cxf-beans.xsd
 http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
 
+    <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/>
+
     <bean id="messageLoss" class="org.apache.cxf.systest.ws.rm.MessageLossSimulator"/>
 
     <cxf:bus>
@@ -42,7 +44,7 @@ http://www.springframework.org/schema/be
                     <wsrm-policy:BaseRetransmissionInterval Milliseconds="60000" />
                 </wsrm-policy:RMAssertion>
                 <wsrm-mgr:store>
-                   <wsrm-mgr:jdbcStore/>
+                   <wsrm-mgr:jdbcStore url="jdbc:derby:${db.name};create=true"/>
                 </wsrm-mgr:store>
             </wsrm-mgr:reliableMessaging>
         </cxf:features>

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent.xml
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent.xml?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent.xml (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/persistent.xml Wed Jun  6 19:02:07 2012
@@ -27,6 +27,8 @@ http://cxf.apache.org/core http://cxf.ap
 http://cxf.apache.org/ws/rm/manager http://cxf.apache.org/schemas/configuration/wsrm-manager.xsd
 http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
     
+    <bean class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer"/>
+    
     <cxf:bus>
         <cxf:features>
             <wsa:addressing/>
@@ -38,6 +40,6 @@ http://www.springframework.org/schema/be
         </cxf:features>
     </cxf:bus>
     
-    <wsrm-mgr:jdbcStore id="testStore"/>
+    <wsrm-mgr:jdbcStore id="testStore" url="jdbc:derby:${db.name};create=true"/>
     
 </beans>
\ No newline at end of file

Modified: cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/sync-ack-persistent-server.xml
URL: http://svn.apache.org/viewvc/cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/sync-ack-persistent-server.xml?rev=1347053&r1=1347052&r2=1347053&view=diff
==============================================================================
--- cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/sync-ack-persistent-server.xml (original)
+++ cxf/branches/2.5.x-fixes/systests/ws-rm/src/test/java/org/apache/cxf/systest/ws/rm/sync-ack-persistent-server.xml Wed Jun  6 19:02:07 2012
@@ -50,6 +50,6 @@
         </cxf:features>
     </cxf:bus>
 
-    <wsrm-mgr:jdbcStore id="testStore"/>
+    <wsrm-mgr:jdbcStore id="testStore" url="jdbc:derby:synack;create=true"/>
 
 </beans>



Mime
View raw message