cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From andreasm...@apache.org
Subject svn commit: r534370 - in /incubator/cxf/trunk: rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/policy/ rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/ rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/ rt/ws/policy/src/te...
Date Wed, 02 May 2007 09:54:28 GMT
Author: andreasmyth
Date: Wed May  2 02:54:26 2007
New Revision: 534370

URL: http://svn.apache.org/viewvc?view=rev&rev=534370
Log:
[JIRA CXF-620] Moved addressing metadata namespace to 02/2007.
[JIRA CXF-479] Test case for server side resend (still disabled).

Added:
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/message-loss-server.xml   (with props)
Modified:
    incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/policy/MetadataConstants.java
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/PolicyTest.java
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/NestedPrimitiveAssertionTest.java
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact0.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact1.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact2.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact3.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact4.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact5.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised1.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised2.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised3.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised4.xml
    incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised5.xml
    incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/Messages.properties
    incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/RetransmissionQueueImpl.java
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-external.xml
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-inline-policy.xml
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm-external.xml
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/MessageLossSimulator.java
    incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/SequenceTest.java
    incubator/cxf/trunk/testutils/src/main/resources/wsdl/greeter_control.wsdl

Modified: incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/policy/MetadataConstants.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/policy/MetadataConstants.java?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/policy/MetadataConstants.java (original)
+++ incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/policy/MetadataConstants.java Wed May  2 02:54:26 2007
@@ -22,12 +22,12 @@
 import javax.xml.namespace.QName;
 
 /**
- * 
+ *
  */
 public final class MetadataConstants {
     
     public static final String NAMESPACE_URI = 
-        "http://www.w3.org/2007/01/addressing/metadata";
+        "http://www.w3.org/2007/02/addressing/metadata";
     public static final String ADDRESSING_ELEM_NAME = "Addressing";
     public static final String ANON_RESPONSES_ELEM_NAME = "AnonymousResponses";
     public static final String NON_ANON_RESPONSES_ELEM_NAME = "NonAnonymousResponses";

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/PolicyTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/PolicyTest.java?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/PolicyTest.java (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/PolicyTest.java Wed May  2 02:54:26 2007
@@ -39,6 +39,8 @@
  */
 public class PolicyTest extends Assert {
  
+    private static final String TEST_NS_URI = "http://cxf.apache.org/test";
+    
     @Test
     public void testContains() {
         List<Assertion> alt1 = new ArrayList<Assertion>();
@@ -148,24 +150,21 @@
     }
     
     Policy getOneAssertion() {
-        String uri = "http://www.w3.org/2007/01/addressing/metadata";
         Policy p = new Policy();
-        p.addAssertion(new PrimitiveAssertion(new QName(uri, "AnonymousResponses"), false));
+        p.addAssertion(new PrimitiveAssertion(new QName(TEST_NS_URI, "AnonymousResponses"), false));
         return p;
     }
     
     Policy getOneOptionalAssertion() {
-        String uri = "http://www.w3.org/2007/01/addressing/metadata";
         Policy p = new Policy();
-        p.addAssertion(new PrimitiveAssertion(new QName(uri, "AnonymousResponses"), true));
+        p.addAssertion(new PrimitiveAssertion(new QName(TEST_NS_URI, "AnonymousResponses"), true));
         return p;
     }
     
     Policy getTwoOptionalAssertions() {
-        String uri = "http://www.w3.org/2007/01/addressing/metadata";
         Policy p = new Policy();
-        p.addAssertion(new PrimitiveAssertion(new QName(uri, "AnonymousResponses"), true));
-        p.addAssertion(new PrimitiveAssertion(new QName(uri, "NonAnonymousResponses"), true));
+        p.addAssertion(new PrimitiveAssertion(new QName(TEST_NS_URI, "AnonymousResponses"), true));
+        p.addAssertion(new PrimitiveAssertion(new QName(TEST_NS_URI, "NonAnonymousResponses"), true));
         return p;
     }
     

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/NestedPrimitiveAssertionTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/NestedPrimitiveAssertionTest.java?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/NestedPrimitiveAssertionTest.java (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/NestedPrimitiveAssertionTest.java Wed May  2 02:54:26 2007
@@ -45,7 +45,7 @@
  */
 public class NestedPrimitiveAssertionTest extends Assert {
 
-    private static final String TEST_NAMESPACE = "http://www.w3.org/2007/01/addressing/metadata";
+    private static final String TEST_NAMESPACE = "http://cxf.apache.org/test";
     private static final QName TEST_NAME1 = new QName(TEST_NAMESPACE, "Addressing");
     private static final QName TEST_NAME2 = new QName(TEST_NAMESPACE, "AnonymousResponses");
     private static final QName TEST_NAME3 = new QName(TEST_NAMESPACE, "NonAnonymousResponses");

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact0.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact0.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact0.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact0.xml Wed May  2 02:54:26 2007
@@ -17,6 +17,6 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsam:Addressing wsp:Optional="true"/>
 </wsp:Policy>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact1.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact1.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact1.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact1.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsam:Addressing wsp:Optional="true">
         <wsp:Policy/>
     </wsam:Addressing>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact2.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact2.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact2.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact2.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsam:Addressing>
         <wsp:Policy/>
     </wsam:Addressing>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact3.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact3.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact3.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact3.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsam:Addressing wsp:Optional="true">
         <wsp:Policy>
             <wsam:AnonymousResponses wsp:Optional="true"/>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact4.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact4.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact4.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact4.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsam:Addressing>
         <wsp:Policy>
             <wsp:ExactlyOne>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact5.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact5.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact5.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/compact5.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsam:Addressing>
         <wsp:Policy>
             <wsam:NonAnonymousResponses/>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised1.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised1.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised1.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised1.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"  xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy"  xmlns:wsam="http://cxf.apache.org/test">
     <wsp:ExactlyOne>
         <wsp:All/>
         <wsp:All>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised2.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised2.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised2.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised2.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsp:ExactlyOne>
         <wsp:All>
             <wsam:Addressing>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised3.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised3.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised3.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised3.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsp:ExactlyOne>
         <wsp:All/>
         <wsp:All>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised4.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised4.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised4.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised4.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsp:ExactlyOne>
         <wsp:All>
             <wsam:Addressing>

Modified: incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised5.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised5.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised5.xml (original)
+++ incubator/cxf/trunk/rt/ws/policy/src/test/java/org/apache/cxf/ws/policy/builder/primitive/resources/normalised5.xml Wed May  2 02:54:26 2007
@@ -17,7 +17,7 @@
   specific language governing permissions and limitations
   under the License.
 -->
-<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+<wsp:Policy xmlns:wsp="http://schemas.xmlsoap.org/ws/2004/09/policy" xmlns:wsam="http://cxf.apache.org/test">
     <wsp:ExactlyOne>
         <wsp:All>
             <wsam:Addressing>

Modified: incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/Messages.properties
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/Messages.properties?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/Messages.properties (original)
+++ incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/Messages.properties Wed May  2 02:54:26 2007
@@ -25,5 +25,6 @@
 SCHEDULE_RESEND_FAILED_MSG = Scheduling of WS-RM retransmission failed.
 RESEND_INITIATION_FAILED_MSG = Failed to initiate retransmission.
 NO_TRANSPORT_FOR_RESEND_MSG = No transport available for WS-RM retransmission.
+NO_ADDRESS_FOR_RESEND_MSG = No address available for WS-RM retransmission.
 MARSHAL_FAULT_DETAIL_EXC = Failed to marshal fault detail.
 SEQ_FAULT_MSG = Reason: {0}, code: {1}, subCode: {2}

Modified: incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/RetransmissionQueueImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/RetransmissionQueueImpl.java?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/RetransmissionQueueImpl.java (original)
+++ incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/soap/RetransmissionQueueImpl.java Wed May  2 02:54:26 2007
@@ -37,16 +37,22 @@
 import java.util.logging.Logger;
 
 import org.apache.cxf.common.logging.LogUtils;
+import org.apache.cxf.endpoint.ConduitSelector;
+import org.apache.cxf.endpoint.DeferredConduitSelector;
 import org.apache.cxf.endpoint.Endpoint;
 import org.apache.cxf.io.AbstractCachedOutputStream;
 import org.apache.cxf.io.CachedOutputStreamCallback;
 import org.apache.cxf.message.Message;
 import org.apache.cxf.message.MessageUtils;
+import org.apache.cxf.service.model.EndpointInfo;
 import org.apache.cxf.transport.Conduit;
+import org.apache.cxf.ws.addressing.AddressingProperties;
+import org.apache.cxf.ws.addressing.AttributedURIType;
 import org.apache.cxf.ws.policy.AssertionInfo;
 import org.apache.cxf.ws.policy.builder.jaxb.JaxbAssertion;
 import org.apache.cxf.ws.rm.Identifier;
 import org.apache.cxf.ws.rm.RMContextUtils;
+import org.apache.cxf.ws.rm.RMEndpoint;
 import org.apache.cxf.ws.rm.RMManager;
 import org.apache.cxf.ws.rm.RMMessageConstants;
 import org.apache.cxf.ws.rm.RMProperties;
@@ -228,6 +234,53 @@
 
     private void clientResend(Message message) {
         Conduit c = message.getExchange().getConduit(message);
+        resend(c, message);
+    }
+
+    private void serverResend(Message message) {
+        RMEndpoint reliableEndpoint = manager.getReliableEndpoint(message);
+        final Endpoint endpoint = reliableEndpoint.getEndpoint();
+        
+        // get the message's to address
+        
+        AddressingProperties maps = RMContextUtils.retrieveMAPs(message, false, true);
+        AttributedURIType to = null;
+        if (null != maps) {
+            to = maps.getTo();
+        }
+        if (null == to) {
+            LOG.log(Level.SEVERE, "NO_ADDRESS_FOR_RESEND_MSG");
+            return;
+        }
+        
+        final String address = to.getValue();
+        LOG.fine("Resending to address: " + address);
+        
+        ConduitSelector cs = new DeferredConduitSelector() {
+            @Override
+            public Conduit selectConduit(Message message) {
+                Conduit conduit = null;
+                EndpointInfo endpointInfo = endpoint.getEndpointInfo();
+                org.apache.cxf.ws.addressing.EndpointReferenceType original = 
+                    endpointInfo.getTarget();
+                try {
+                    if (null != address) {
+                        endpointInfo.setAddress(address);
+                    }
+                    conduit = super.selectConduit(message);
+                } finally {
+                    endpointInfo.setAddress(original);
+                }
+                return conduit;
+            }
+        };
+        
+        
+        Conduit c = cs.selectConduit(message);
+        resend(c, message);
+    }
+    
+    private void resend(Conduit c, Message message) {
         try {
 
             // get registered callbacks, create new output stream and
@@ -262,10 +315,6 @@
         } catch (IOException ex) {
             LOG.log(Level.SEVERE, "RESEND_FAILED_MSG", ex);
         }
-    }
-
-    private void serverResend(Message message) {
-        // TODO
     }
 
     /**

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-external.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-external.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-external.xml (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-external.xml Wed May  2 02:54:26 2007
@@ -25,7 +25,7 @@
             </wsa:EndpointReference>
         </wsp:AppliesTo>
         <wsp:Policy>
-            <wsam:Addressing xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+            <wsam:Addressing xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
                 <wsp:Policy/>
             </wsam:Addressing>
         </wsp:Policy>

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-inline-policy.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-inline-policy.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-inline-policy.xml (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr-inline-policy.xml Wed May  2 02:54:26 2007
@@ -52,7 +52,7 @@
 
 	<wsp:Policy wsu:Id="AddressingPolicy"
 	    xmlns:wsp="http://www.w3.org/2006/07/ws-policy"
-		xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+		xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
 		<wsam:Addressing>
 			<wsp:Policy />
 		</wsam:Addressing>

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl Wed May  2 02:54:26 2007
@@ -190,7 +190,7 @@
             <soap:address location="http://localhost:9020/SoapContext/GreeterPort"/>
             <!--
             <wsp:Policy xmlns:wsp="http://www.w3.org/2006/07/ws-policy">
-                <wsam:Addressing xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+                <wsam:Addressing xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
                     <wsp:Policy/>
                 </wsam:Addressing>
             </wsp:Policy>

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm-external.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm-external.xml?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm-external.xml (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm-external.xml Wed May  2 02:54:26 2007
@@ -25,7 +25,7 @@
             </wsa:EndpointReference>
         </wsp:AppliesTo>
         <wsp:Policy>
-            <wsam:Addressing xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+            <wsam:Addressing xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
                 <wsp:Policy/>
             </wsam:Addressing>
             <wsrmp:RMAssertion xmlns:wsrmp="http://schemas.xmlsoap.org/ws/2005/02/rm/policy">

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/MessageLossSimulator.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/MessageLossSimulator.java?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/MessageLossSimulator.java (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/MessageLossSimulator.java Wed May  2 02:54:26 2007
@@ -31,6 +31,7 @@
 import org.apache.cxf.interceptor.MessageSenderInterceptor;
 import org.apache.cxf.io.AbstractWrappedOutputStream;
 import org.apache.cxf.message.Message;
+import org.apache.cxf.message.MessageUtils;
 import org.apache.cxf.phase.AbstractPhaseInterceptor;
 import org.apache.cxf.phase.Phase;
 import org.apache.cxf.phase.PhaseInterceptor;
@@ -60,6 +61,9 @@
             action = maps.getAction().getValue();
         }
         if (RMContextUtils.isRMProtocolMessage(action)) {
+            return;
+        }
+        if (MessageUtils.isPartialResponse(message)) {
             return;
         }
         appMessageCount++;

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/SequenceTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/SequenceTest.java?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/SequenceTest.java (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/SequenceTest.java Wed May  2 02:54:26 2007
@@ -111,6 +111,9 @@
     private boolean doTestTwowayMessageLossAsyncExecutor = testAll;
     private boolean doTestTwowayNonAnonymousNoOffer = testAll;
     private boolean doTestConcurrency = testAll;
+    private boolean doTestMultiClientOneway = testAll;
+    private boolean doTestMultiClientTwoway = testAll;
+    private boolean doTestServerSideMessageLoss = testAll;
 
     @BeforeClass
     public static void startServers() throws Exception {
@@ -120,17 +123,8 @@
     
     @After
     public void tearDown() {
-        if (null != greeter) {
-            assertTrue("Failed to stop greeter.", control.stopGreeter(null));                        
-            RMManager manager = greeterBus.getExtension(RMManager.class);
-            manager.shutdown();
-            greeterBus.shutdown(true);
-            greeterBus = null;
-        }
-        if (null != control) {  
-            assertTrue("Failed to stop greeter", control.stopGreeter(null));
-            controlBus.shutdown(true);
-        }
+        stopGreeter();
+        stopControl();
     }
 
     /** 
@@ -182,7 +176,7 @@
         if (!doTestOnewayAnonymousAcks) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/rminterceptors.xml");
+        init("org/apache/cxf/systest/ws/rm/rminterceptors.xml");
 
         greeter.greetMeOneWay("once");
         greeter.greetMeOneWay("twice");
@@ -214,7 +208,7 @@
         if (!doTestOnewayDeferredAnonymousAcks) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/deferred.xml");
+        init("org/apache/cxf/systest/ws/rm/deferred.xml");
 
         greeter.greetMeOneWay("once");
         greeter.greetMeOneWay("twice");
@@ -253,7 +247,7 @@
         if (!doTestOnewayDeferredNonAnonymousAcks) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/deferred.xml", true);
+        init("org/apache/cxf/systest/ws/rm/deferred.xml", true);
 
         greeter.greetMeOneWay("once");
         greeter.greetMeOneWay("twice");
@@ -307,7 +301,7 @@
         if (!doTestOnewayAnonymousAcksSequenceLength1) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/seqlength1.xml");
+        init("org/apache/cxf/systest/ws/rm/seqlength1.xml");
 
         greeter.greetMeOneWay("once");
         greeter.greetMeOneWay("twice");
@@ -363,7 +357,7 @@
 
     private void testOnewayAnonymousAcksSuppressed(Executor executor) throws Exception {
 
-        setupGreeter("org/apache/cxf/systest/ws/rm/suppressed.xml", false, executor);
+        init("org/apache/cxf/systest/ws/rm/suppressed.xml", false, executor);
  
         greeter.greetMeOneWay("once");
         greeter.greetMeOneWay("twice");
@@ -410,7 +404,7 @@
         if (!doTestTwowayNonAnonymous) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/rminterceptors.xml", true);
+        init("org/apache/cxf/systest/ws/rm/rminterceptors.xml", true);
 
         greeter.greetMe("one");
         greeter.greetMe("two");
@@ -460,7 +454,7 @@
         if (!doTestTwowayNonAnonymousEndpointSpecific) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/twoway-endpoint-specific.xml", true);
+        init("org/apache/cxf/systest/ws/rm/twoway-endpoint-specific.xml", true);
 
 
         greeter.greetMe("one");
@@ -509,7 +503,7 @@
         if (!doTestTwowayNonAnonymousDeferred) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/deferred.xml", true);
+        init("org/apache/cxf/systest/ws/rm/deferred.xml", true);
 
         greeter.greetMe("one");
         greeter.greetMe("two");
@@ -575,7 +569,7 @@
         if (!doTestTwowayNonAnonymousMaximumSequenceLength2) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/seqlength10.xml", true);
+        init("org/apache/cxf/systest/ws/rm/seqlength10.xml", true);
         
         RMManager manager = greeterBus.getExtension(RMManager.class);
         assertEquals("Unexpected maximum sequence length.", BigInteger.TEN, 
@@ -635,7 +629,7 @@
             return;
         }
         
-        setupGreeter("org/apache/cxf/systest/ws/rm/atmostonce.xml");
+        init("org/apache/cxf/systest/ws/rm/atmostonce.xml");
         
         class MessageNumberInterceptor extends AbstractPhaseInterceptor {
             public MessageNumberInterceptor() {
@@ -704,7 +698,7 @@
             return;
         }
         
-        setupGreeter("org/apache/cxf/systest/ws/rm/rminterceptors.xml");
+        init("org/apache/cxf/systest/ws/rm/rminterceptors.xml");
         
         class SequenceIdInterceptor extends AbstractPhaseInterceptor {
             public SequenceIdInterceptor() {
@@ -743,7 +737,7 @@
             return;
         }
         
-        setupGreeter("org/apache/cxf/systest/ws/rm/inactivity-timeout.xml");
+        init("org/apache/cxf/systest/ws/rm/inactivity-timeout.xml");
        
         greeter.greetMe("one");
         
@@ -818,7 +812,7 @@
 
     private void testOnewayMessageLoss(Executor executor) throws Exception {
 
-        setupGreeter("org/apache/cxf/systest/ws/rm/message-loss.xml", false, executor);
+        init("org/apache/cxf/systest/ws/rm/message-loss.xml", false, executor);
         
         greeterBus.getOutInterceptors().add(new MessageLossSimulator());
         RMManager manager = greeterBus.getExtension(RMManager.class);
@@ -881,7 +875,7 @@
     
     private void testTwowayMessageLoss(Executor executor) throws Exception {
 
-        setupGreeter("org/apache/cxf/systest/ws/rm/message-loss.xml", true, executor);
+        init("org/apache/cxf/systest/ws/rm/message-loss.xml", true, executor);
         
         greeterBus.getOutInterceptors().add(new MessageLossSimulator());
         RMManager manager = greeterBus.getExtension(RMManager.class);
@@ -938,7 +932,7 @@
         if (!doTestTwowayNonAnonymousNoOffer) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/no-offer.xml", true);        
+        init("org/apache/cxf/systest/ws/rm/no-offer.xml", true);        
         
         greeter.greetMe("one");
         // greeter.greetMe("two");
@@ -974,7 +968,7 @@
         if (!doTestConcurrency) {
             return;
         }
-        setupGreeter("org/apache/cxf/systest/ws/rm/rminterceptors.xml", true);
+        init("org/apache/cxf/systest/ws/rm/rminterceptors.xml", true);
 
         for (int i = 0; i < 5; i++) {
             greeter.greetMeAsync(Integer.toString(i));
@@ -994,27 +988,268 @@
         }
         mf.verifyActions(expectedActions, true);
     }
+    @Test
+    public void testMultiClientOneway() throws Exception {
+        if (!doTestMultiClientOneway) {
+            return;
+        }
+        
+        SpringBusFactory bf = new SpringBusFactory();
+        String cfgResource = "org/apache/cxf/systest/ws/rm/rminterceptors.xml";            
+        initControl(bf, cfgResource);
+    
+        class ClientThread extends Thread {
+            
+            Greeter greeter;
+            Bus greeterBus;
+            InMessageRecorder inRecorder;
+            OutMessageRecorder outRecorder;  
+            String id;
+            
+            ClientThread(SpringBusFactory bf, String cfgResource, int n) { 
+                SequenceTest.this.initGreeter(bf, cfgResource, false, null);
+                greeter = SequenceTest.this.greeter;
+                greeterBus = SequenceTest.this.greeterBus;
+                inRecorder = SequenceTest.this.inRecorder;
+                outRecorder = SequenceTest.this.outRecorder;
+                id = "client " + n;
+            }
+            
+            public void run() {
+                greeter.greetMeOneWay(id + ": once");
+                greeter.greetMeOneWay(id + ": twice");
+                greeter.greetMeOneWay(id + ": thrice");
+
+                // three application messages plus createSequence
+
+                awaitMessages(4, 4);
+            }
+        }
+        
+        ClientThread clients[] = new ClientThread[2];
+        
+        try {
+            for (int i = 0; i < clients.length; i++) {
+                clients[i] = new ClientThread(bf, cfgResource, i);
+            }
+
+            for (int i = 0; i < clients.length; i++) {
+                clients[i].start();
+            }
+
+            for (int i = 0; i < clients.length; i++) {
+                clients[i].join();
+                MessageFlow mf = new MessageFlow(clients[i].outRecorder.getOutboundMessages(),
+                                                 clients[i].inRecorder.getInboundMessages());
+
+                mf.verifyMessages(4, true);
+                String[] expectedActions = new String[] {RMConstants.getCreateSequenceAction(),
+                                                         GREETMEONEWAY_ACTION, GREETMEONEWAY_ACTION,
+                                                         GREETMEONEWAY_ACTION};
+                mf.verifyActions(expectedActions, true);
+                mf.verifyMessageNumbers(new String[] {null, "1", "2", "3"}, true);
+
+                // createSequenceResponse plus 3 partial responses
+
+                mf.verifyMessages(4, false);
+                expectedActions = new String[] {RMConstants.getCreateSequenceResponseAction(), null, null,
+                                                null};
+                mf.verifyActions(expectedActions, false);
+                mf.verifyMessageNumbers(new String[] {null, null, null, null}, false);
+                mf.verifyAcknowledgements(new boolean[] {false, true, true, true}, false);
+
+            }
+        } finally {
+            for (int i = 0; i < clients.length; i++) {
+                greeter = clients[i].greeter;
+                greeterBus = clients[i].greeterBus;
+                stopGreeter();                
+            }
+            greeter = null;
+        }        
+    }
+    
+    @Test
+    public void testMultiClientTwoway() throws Exception {
+        if (!doTestMultiClientTwoway) {
+            return;
+        }
+        
+        SpringBusFactory bf = new SpringBusFactory();
+        String cfgResource = "org/apache/cxf/systest/ws/rm/rminterceptors.xml";            
+        initControl(bf, cfgResource);
+    
+        class ClientThread extends Thread {
+            
+            Greeter greeter;
+            Bus greeterBus;
+            InMessageRecorder inRecorder;
+            OutMessageRecorder outRecorder;  
+            String id;
+            
+            ClientThread(SpringBusFactory bf, String cfgResource, int n) { 
+                SequenceTest.this.initGreeter(bf, cfgResource, true, null);
+                greeter = SequenceTest.this.greeter;
+                greeterBus = SequenceTest.this.greeterBus;
+                inRecorder = SequenceTest.this.inRecorder;
+                outRecorder = SequenceTest.this.outRecorder;
+                id = "client " + n;
+            }
+            
+            public void run() {
+                greeter.greetMe(id + ": a");
+                greeter.greetMe(id + ": b");
+                greeter.greetMe(id + ": c");
+
+                // three application messages plus createSequence
+
+                awaitMessages(4, 8);
+            }
+        }
+        
+        ClientThread clients[] = new ClientThread[2];
+        
+        try {
+            for (int i = 0; i < clients.length; i++) {
+                clients[i] = new ClientThread(bf, cfgResource, i);
+            }
+
+            for (int i = 0; i < clients.length; i++) {
+                clients[i].start();
+            }
+
+            for (int i = 0; i < clients.length; i++) {
+                clients[i].join();
+                MessageFlow mf = new MessageFlow(clients[i].outRecorder.getOutboundMessages(), 
+                                                 clients[i].inRecorder.getInboundMessages());
+                                
+                mf.verifyMessages(4, true);
+                String[] expectedActions = new String[] {RMConstants.getCreateSequenceAction(), 
+                                                         GREETME_ACTION,
+                                                         GREETME_ACTION, 
+                                                         GREETME_ACTION};
+                mf.verifyActions(expectedActions, true);
+                mf.verifyMessageNumbers(new String[] {null, "1", "2", "3"}, true);
+                mf.verifyLastMessage(new boolean[] {false, false, false, false}, true);
+                mf.verifyAcknowledgements(new boolean[] {false, false, true, true}, true);
+
+                // createSequenceResponse plus 3 greetMeResponse messages plus
+                // one partial response for each of the four messages
+                // the first partial response should no include an acknowledgement, the other three should
+
+                mf.verifyMessages(8, false);
+                mf.verifyPartialResponses(4, new boolean[4]);
+
+                mf.purgePartialResponses();
+
+                expectedActions = new String[] {RMConstants.getCreateSequenceResponseAction(), 
+                                                GREETME_RESPONSE_ACTION, 
+                                                GREETME_RESPONSE_ACTION, 
+                                                GREETME_RESPONSE_ACTION};
+                mf.verifyActions(expectedActions, false);
+                mf.verifyMessageNumbers(new String[] {null, "1", "2", "3"}, false);
+                mf.verifyLastMessage(new boolean[4], false);
+                mf.verifyAcknowledgements(new boolean[] {false, true, true, true}, false);
+
+            }
+        } finally {
+            for (int i = 0; i < clients.length; i++) {
+                greeter = clients[i].greeter;
+                greeterBus = clients[i].greeterBus;
+                stopGreeter();                
+            }
+            greeter = null;
+        }        
+    }
+    
+    @Ignore
+    @Test
+    public void testServerSideMessageLoss() throws Exception {
+        if (!doTestServerSideMessageLoss) {
+            return;
+        }
+        init("org/apache/cxf/systest/ws/rm/message-loss-server.xml", true);
+        
+        // avoid client side message loss
+        List<Interceptor> outInterceptors = greeterBus.getOutInterceptors();
+        for (Interceptor i : outInterceptors) {
+            if (i.getClass().equals(MessageLossSimulator.class)) {
+                outInterceptors.remove(i);
+                break;
+            }
+        }
+        // avoid client side resends
+        greeterBus.getExtension(RMManager.class).getRMAssertion().getBaseRetransmissionInterval()
+            .setMilliseconds(new BigInteger("60000"));
+
+        greeter.greetMe("one");
+        greeter.greetMe("two");
+
+        // outbound: CreateSequence and two greetMe messages 
+
+        awaitMessages(3, 6);
+        
+        MessageFlow mf = new MessageFlow(outRecorder.getOutboundMessages(), inRecorder.getInboundMessages());
+        
+        
+        mf.verifyMessages(3, true);
+        String[] expectedActions = new String[] {RMConstants.getCreateSequenceAction(), 
+                                                 GREETME_ACTION, 
+                                                 GREETME_ACTION};
+        mf.verifyActions(expectedActions, true);
+        mf.verifyMessageNumbers(new String[] {null, "1", "2"}, true);
+        mf.verifyLastMessage(new boolean[] {false, false, false}, true);
+        mf.verifyAcknowledgements(new boolean[] {false, false, true}, true);
+
+        // createSequenceResponse plus 2 greetMeResponse messages plus
+        // one partial response for each of the four messages
+        // the first partial response should no include an acknowledgement, the other three should
+
+        mf.verifyMessages(6, false);
+        mf.verifyPartialResponses(3, new boolean[3]);
+
+        mf.purgePartialResponses();
+
+        expectedActions = new String[] {RMConstants.getCreateSequenceResponseAction(), 
+                                        GREETME_RESPONSE_ACTION, 
+                                        GREETME_RESPONSE_ACTION};
+        mf.verifyActions(expectedActions, false);
+        mf.verifyMessageNumbers(new String[] {null, "1", "2"}, false);
+        mf.verifyLastMessage(new boolean[3], false);
+        mf.verifyAcknowledgements(new boolean[] {false, true, true}, false);
+    }
+    
+    
 
     // --- test utilities ---
 
-    private void setupGreeter(String cfgResource) {
-        setupGreeter(cfgResource, false);
+    private void init(String cfgResource) {
+        init(cfgResource, false);
     }
 
-    private void setupGreeter(String cfgResource, boolean useDecoupledEndpoint) {
-        setupGreeter(cfgResource, useDecoupledEndpoint, null);
+    private void init(String cfgResource, boolean useDecoupledEndpoint) {
+        init(cfgResource, useDecoupledEndpoint, null);
     }
     
-    private void setupGreeter(String cfgResource, boolean useDecoupledEndpoint, Executor executor) {
+    private void init(String cfgResource, boolean useDecoupledEndpoint, Executor executor) {
         
         SpringBusFactory bf = new SpringBusFactory();
-        
+        initControl(bf, cfgResource);
+        initGreeter(bf, cfgResource, useDecoupledEndpoint, executor);
+    }
+    
+    private void initControl(SpringBusFactory bf, String cfgResource) {
         controlBus = bf.createBus();
         BusFactory.setDefaultBus(controlBus);
 
         ControlService cs = new ControlService();
         control = cs.getControlPort();
         
+        assertTrue("Failed to start greeter", control.startGreeter(cfgResource));        
+    }
+    
+    private void initGreeter(SpringBusFactory bf, String cfgResource, 
+                             boolean useDecoupledEndpoint, Executor executor) {
         greeterBus = bf.createBus(cfgResource);
         BusFactory.setDefaultBus(greeterBus);
         LOG.fine("Initialised greeter bus with configuration: " + cfgResource);
@@ -1023,8 +1258,6 @@
         greeterBus.getOutInterceptors().add(outRecorder);
         inRecorder = new InMessageRecorder();
         greeterBus.getInInterceptors().add(inRecorder);
-
-        assertTrue("Failed to start greeter", control.startGreeter(cfgResource));
         
         GreeterService gs = new GreeterService();
 
@@ -1051,6 +1284,22 @@
         cp.setDecoupledEndpoint(decoupledEndpoint);
 
         LOG.fine("Using decoupled endpoint: " + cp.getDecoupledEndpoint());
+    }
+    
+    private void stopGreeter() {
+        if (null != greeter) {                       
+            RMManager manager = greeterBus.getExtension(RMManager.class);
+            manager.shutdown();
+            greeterBus.shutdown(true);
+            greeterBus = null;
+        }
+    }
+    
+    private void stopControl() {
+        if (null != control) {  
+            assertTrue("Failed to stop greeter", control.stopGreeter(null));
+            controlBus.shutdown(true);
+        }
     }
     
     private void awaitMessages(int nExpectedOut, int nExpectedIn) {

Added: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/message-loss-server.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/message-loss-server.xml?view=auto&rev=534370
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/message-loss-server.xml (added)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/message-loss-server.xml Wed May  2 02:54:26 2007
@@ -0,0 +1,88 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+	Licensed to the Apache Software Foundation (ASF) under one
+	or more contributor license agreements. See the NOTICE file
+	distributed with this work for additional information
+	regarding copyright ownership. The ASF licenses this file
+	to you under the Apache License, Version 2.0 (the
+	"License"); you may not use this file except in compliance
+	with the License. You may obtain a copy of the License at
+	
+	http://www.apache.org/licenses/LICENSE-2.0
+	
+	Unless required by applicable law or agreed to in writing,
+	software distributed under the License is distributed on an
+	"AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+	KIND, either express or implied. See the License for the
+	specific language governing permissions and limitations
+	under the License.
+-->
+<beans xmlns="http://www.springframework.org/schema/beans"
+	xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xmlns:wsrm-mgmt="http://cxf.apache.org/ws/rm/manager"
+	xmlns:wsrm-policy="http://schemas.xmlsoap.org/ws/2005/02/rm/policy"
+	xmlns:http-conf="http://cxf.apache.org/transports/http/configuration"
+	xsi:schemaLocation="
+http://cxf.apache.org/ws/rm/manager http://cxf.apache.org/ws/rm/manager.xsd
+http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+	<bean id="mapAggregator" class="org.apache.cxf.ws.addressing.MAPAggregator"/>
+    <bean id="mapCodec" class="org.apache.cxf.ws.addressing.soap.MAPCodec"/>
+    <bean id="rmLogicalOut" class="org.apache.cxf.ws.rm.RMOutInterceptor">
+        <property name="bus" ref="cxf"/>
+    </bean>
+    <bean id="rmLogicalIn" class="org.apache.cxf.ws.rm.RMInInterceptor">
+        <property name="bus" ref="cxf"/>
+    </bean>
+    <bean id="rmCodec" class="org.apache.cxf.ws.rm.soap.RMSoapInterceptor"/>
+    <bean id="messageLoss" class="org.apache.cxf.systest.ws.rm.MessageLossSimulator"/>
+
+    <!-- We are adding the interceptors to the bus as we will have only one endpoint/service/bus. -->
+
+    <bean id="cxf" class="org.apache.cxf.bus.CXFBusImpl">
+        <property name="inInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+                <ref bean="rmLogicalIn"/>
+                <ref bean="rmCodec"/>
+            </list>
+        </property>
+        <property name="inFaultInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+                <ref bean="rmLogicalIn"/>
+                <ref bean="rmCodec"/>
+            </list>
+        </property>
+        <property name="outInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+                <ref bean="rmLogicalOut"/>
+                <ref bean="rmCodec"/>
+                <ref bean="messageLoss"/>
+            </list>
+        </property>
+        <property name="outFaultInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+                <ref bean="rmLogicalOut"/>
+                <ref bean="rmCodec"/>
+            </list>
+        </property>
+    </bean>
+	
+	
+
+	<wsrm-mgmt:rmManager id="org.apache.cxf.ws.rm.RMManager">
+		<wsrm-policy:RMAssertion>
+			<!-- avoid server side resends, change programatically for client -->
+			<wsrm-policy:BaseRetransmissionInterval Milliseconds="2000" />
+		</wsrm-policy:RMAssertion>
+	</wsrm-mgmt:rmManager>
+
+
+</beans>
\ No newline at end of file

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/message-loss-server.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/message-loss-server.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/rm/message-loss-server.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Modified: incubator/cxf/trunk/testutils/src/main/resources/wsdl/greeter_control.wsdl
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/testutils/src/main/resources/wsdl/greeter_control.wsdl?view=diff&rev=534370&r1=534369&r2=534370
==============================================================================
--- incubator/cxf/trunk/testutils/src/main/resources/wsdl/greeter_control.wsdl (original)
+++ incubator/cxf/trunk/testutils/src/main/resources/wsdl/greeter_control.wsdl Wed May  2 02:54:26 2007
@@ -284,7 +284,7 @@
         <wsdl:port binding="tns:GreeterSOAPBinding" name="GreeterPort">
             <soap:address location="http://localhost:9020/SoapContext/GreeterPort"/>
             <wsp:Policy xmlns:wsp="http://www.w3.org/2006/07/ws-policy">
-                <wsam:Addressing xmlns:wsam="http://www.w3.org/2007/01/addressing/metadata">
+                <wsam:Addressing xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
                     <wsp:Policy/>
                 </wsam:Addressing>
                 <wsrmp:RMAssertion xmlns:wsrmp="http://schemas.xmlsoap.org/ws/2005/02/rm/policy">



Mime
View raw message