cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From egl...@apache.org
Subject svn commit: r474877 - in /incubator/cxf/trunk: api/src/main/java/org/apache/cxf/message/ distribution/src/main/release/samples/ws_addressing/ distribution/src/main/release/samples/ws_addressing/src/ distribution/src/main/release/samples/ws_addressing/s...
Date Tue, 14 Nov 2006 17:13:46 GMT
Author: eglynn
Date: Tue Nov 14 09:13:44 2006
New Revision: 474877

URL: http://svn.apache.org/viewvc?view=rev&rev=474877
Log:
Fixed up fault-handling issues that were impacting on WS-A demo

Added:
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/README.txt
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/README.txt
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/build.xml
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/build.xml
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/client.xml
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/celtix-client.xml
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/server.xml
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/celtix-server.xml
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/client/
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/client/Client.java
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/client/Client.java
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/handler_chain.xml   (with props)
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/Server.java
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/server/Server.java
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/wsdl/
    incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/wsdl/hello_world_addr.wsdl
      - copied, changed from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/wsdl/hello_world_addr.wsdl
Modified:
    incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/Exchange.java
    incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/ExchangeImpl.java
    incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/MessageImpl.java
    incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/ReadHeadersInterceptor.java
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/endpoint/ClientImpl.java
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractFaultChainIntiatorObserver.java
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/ClientOutFaultObserver.java
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/InFaultChainInitiatorObserver.java
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutFaultChainInitiatorObserver.java
    incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainSetupInterceptor.java
    incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/AbstractJAXWSHandlerInterceptor.java
    incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/ContextUtils.java
    incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java
    incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/soap/MAPCodec.java
    incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/MAPAggregatorTest.java
    incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/soap/MAPCodecTest.java
    incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/AbstractRMInterceptor.java
    incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMContextUtils.java
    incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMManagerTest.java

Modified: incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/Exchange.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/Exchange.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/Exchange.java (original)
+++ incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/Exchange.java Tue Nov 14 09:13:44 2006
@@ -32,8 +32,11 @@
     Message getOutMessage();
     void setOutMessage(Message m);
     
-    Message getFaultMessage();
-    void setFaultMessage(Message m);
+    Message getInFaultMessage();
+    void setInFaultMessage(Message m);
+
+    Message getOutFaultMessage();
+    void setOutFaultMessage(Message m);
     
     Session getSession();
     

Modified: incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/ExchangeImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/ExchangeImpl.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/ExchangeImpl.java (original)
+++ incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/ExchangeImpl.java Tue Nov 14 09:13:44 2006
@@ -33,7 +33,8 @@
     
     private Message inMessage;
     private Message outMessage;
-    private Message faultMessage;
+    private Message inFaultMessage;
+    private Message outFaultMessage;
     
     private Session session;
     
@@ -53,12 +54,21 @@
         return outMessage;
     }
 
-    public Message getFaultMessage() {
-        return faultMessage;
+    public Message getInFaultMessage() {
+        return inFaultMessage;
     }
 
-    public void setFaultMessage(Message m) {
-        this.faultMessage = m;
+    public void setInFaultMessage(Message m) {
+        inFaultMessage = m;
+        m.setExchange(this);
+    }
+
+    public Message getOutFaultMessage() {
+        return outFaultMessage;
+    }
+
+    public void setOutFaultMessage(Message m) {
+        outFaultMessage = m;
         m.setExchange(this);
     }
 

Modified: incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/MessageImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/MessageImpl.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/MessageImpl.java (original)
+++ incubator/cxf/trunk/api/src/main/java/org/apache/cxf/message/MessageImpl.java Tue Nov 14 09:13:44 2006
@@ -153,7 +153,11 @@
     
     public static void copyContent(Message m1, Message m2) {
         for (Class<?> c : m1.getContentFormats()) {
-            m2.setContent(c, m1.getContent(c));
+            if (c == Exception.class) {
+                m2.setContent(c, m1.getContent(c));
+            } else if (c ==  javax.xml.stream.XMLStreamReader.class) {
+                m2.setContent(c, m1.getContent(c));
+            }
         }
     }
 }

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/README.txt (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/README.txt)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/README.txt?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/README.txt&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/README.txt&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/README.txt (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/README.txt Tue Nov 14 09:13:44 2006
@@ -1,15 +1,15 @@
 WS-Addressing Demo
 ==================
 
-This demo shows how WS-Addressing support in Celtix may be enabled.  
+This demo shows how WS-Addressing support in CXF may be enabled.  
 
-The client and server both use handler configuration to install the
-WS-Addressing handlers, comprising a LogicalHandler (MAPAggregator)
+The client and server both use interceptor configuration to install the
+WS-Addressing interceptor, comprising a logical interceptor (MAPAggregator)
 responsible for aggregating the WS-A MessageAddressingProperties for
-the current message, and a ProtocolHandler (MAPCodec) responsible for
+the current message, and a protocol interceptor (MAPCodec) responsible for
 encoding/decoding these properties as SOAP Headers. 
 
-An additional demo-specific ProtocolHandler (HeaderSnooper) is used to
+An additional demo-specific protocol handler (HeaderSnooper) is used to
 snoop the SOAP Headers and display these to the console.
 
 Normally the WS-Addressing MessageAddressProperties are generated and
@@ -38,7 +38,7 @@
 Prerequisite
 ------------
 
-If your environment already includes celtix.jar on the CLASSPATH,
+If your environment already includes cxf-incubator.jar on the CLASSPATH,
 and the JDK and ant bin directories on the PATH, it is not necessary to
 run the environment script described in the samples directory README.
 If your environment is not properly configured, or if you are planning
@@ -89,13 +89,13 @@
 
 For UNIX:  
   
-  export CLASSPATH=$CLASSPATH:$CELTIX_HOME/lib/celtix.jar:./build/classes
+  export CLASSPATH=$CLASSPATH:$CXF_HOME/lib/cxf-incubator.jar:./build/classes
   javac -d build/classes src/demo/ws_addressing/common/*.java
   javac -d build/classes src/demo/ws_addressing/client/*.java
   javac -d build/classes src/demo/ws_addressing/server/*.java
 
 For Windows:
-  set classpath=%classpath%;%CELTIX_HOME%\lib\celtix.jar;.\build\classes
+  set classpath=%classpath%;%CXF_HOME%\lib\cxf-incubator.jar;.\build\classes
   javac -d build\classes src\demo\ws_addressing\common\*.java
   javac -d build\classes src\demo\ws_addressing\client\*.java
   javac -d build\classes src\demo\ws_addressing\server\*.java
@@ -106,24 +106,24 @@
 From the samples/ws_addressing directory run the commands (entered on a single command line):
 
 For UNIX (must use forward slashes):
-    java -Djava.util.logging.config.file=$CELTIX_HOME/etc/logging.properties
-         -Dceltix.config.file=file:///$CELTIX_HOME/samples/ws_addressing/celtix-server.xml
+    java -Djava.util.logging.config.file=$CXF_HOME/etc/logging.properties
+         -Dcxf.config.file=file:///$CXF_HOME/samples/ws_addressing/server.xml
          demo.ws_addressing.server.Server &
 
-    java -Djava.util.logging.config.file=$CELTIX_HOME/etc/logging.properties
-         -Dceltix.config.file=file:///$CELTIX_HOME/samples/ws_addressing/celtix-client.xml
+    java -Djava.util.logging.config.file=$CXF_HOME/etc/logging.properties
+         -Dcxf.config.file=file:///$CXF_HOME/samples/ws_addressing/client.xml
          demo.ws_addressing.client.Client ./wsdl/hello_world_addr.wsdl
 
 The server process starts in the background.
 
 For Windows (may use either forward or back slashes):
   start 
-    java -Djava.util.logging.config.file=%CELTIX_HOME%\etc\logging.properties
-         -Dceltix.config.file=file:///%CELTIX_HOME%\samples\ws_addressing\celtix-client.xml
+    java -Djava.util.logging.config.file=%CXF_HOME%\etc\logging.properties
+         -Dcxf.config.file=file:///%CXF_HOME%\samples\ws_addressing\client.xml
          demo.ws_addressing.server.Server
 
-    java -Djava.util.logging.config.file=%CELTIX_HOME%\etc\logging.properties
-         -Dceltix.config.file=file:///%CELTIX_HOME%\samples\ws_addressing\celtix-client.xml
+    java -Djava.util.logging.config.file=%CXF_HOME%\etc\logging.properties
+         -Dcxf.config.file=file:///%CXF_HOME%\samples\ws_addressing\client.xml
          demo.ws_addressing.client.Client .\wsdl\hello_world_addr.wsdl
 
 The server process starts in a new command window.

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/build.xml (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/build.xml)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/build.xml?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/build.xml&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/build.xml&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/build.xml (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/build.xml Tue Nov 14 09:13:44 2006
@@ -1,14 +1,36 @@
 <?xml version="1.0"?>
+<!--
+  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.
+-->
 <project name="WS-Addressing demo" default="build" basedir=".">
 
     <import file="../common_build.xml"/>
 
     <target name="client" description="run demo client" depends="build">
-        <celtixrun classname="demo.ws_addressing.client.Client" param1="${basedir}/wsdl/hello_world_addr.wsdl"  jvmarg1="-Dceltix.config.file=file:///${basedir}/celtix-client.xml"/>
+        <cxfrun classname="demo.ws_addressing.client.Client"
+                 param1="${basedir}/wsdl/hello_world_addr.wsdl"
+                 jvmarg1="-Dcxf.config.file=client.xml"/>
     </target>
 
     <target name="server" description="run demo server" depends="build">
-        <celtixrun classname="demo.ws_addressing.server.Server" param1="${basedir}/wsdl/hello_world_addr.wsdl" jvmarg1="-Dceltix.config.file=file:///${basedir}/celtix-server.xml"/>
+        <cxfrun classname="demo.ws_addressing.server.Server"
+                 param1="${basedir}/wsdl/hello_world_addr.wsdl"
+                 jvmarg1="-Dcxf.config.file=server.xml"/>
     </target>
 
     <target name="generate.code">

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/client.xml (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/celtix-client.xml)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/client.xml?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/celtix-client.xml&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/client.xml&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/celtix-client.xml (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/client.xml Tue Nov 14 09:13:44 2006
@@ -1,51 +1,59 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE beans SYSTEM 
-     "http://celtix.objectweb.org/configuration/spring/celtix-spring-beans.dtd">
+<!--
+  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:http-conf="http://cxf.apache.org/transports/http/configuration"
+       xsi:schemaLocation="
+http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+  
+    <bean name="{http://apache.org/hello_world_soap_http}SoapPort.http-conduit" abstract="true">     
+        <property name="client">
+            <value>
+                <http-conf:client DecoupledEndpoint="http://localhost:9999/decoupled_endpoint"/>
+            </value>
+        </property>
+    </bean>
 
-<beans xmlns:http-conf="http://celtix.objectweb.org/transports/http/configuration"
-       xmlns:jaxws-types="http://celtix.objectweb.org/bus/jaxws/configuration/types">
+    <bean id="mapAggregator" class="org.apache.cxf.ws.addressing.MAPAggregator"/>
+    <bean id="mapCodec" class="org.apache.cxf.ws.addressing.soap.MAPCodec"/>
 
-  <bean id="celtix.{http://objectweb.org/hello_world_soap_http}SOAPService/SoapPort.http-client"
-        class="org.objectweb.celtix.bus.transports.http.http_client_config.spring.HttpClientConfigBean">     
-      <property name="httpClient">
-          <value>
-              <http-conf:client DecoupledEndpoint="http://localhost:9999/decoupled_endpoint"/>
-          </value>
-      </property>
-  </bean>
+    <!-- We are adding the interceptors to the bus as we will have only one endpoint/service/bus. -->
 
-  <bean id="celtix.{http://objectweb.org/hello_world_soap_http}SOAPService/SoapPort" 
-        class="org.objectweb.celtix.bus.jaxws.port_config.spring.PortConfigBean">
-      <property name="systemHandlerChain">
-          <value>
-              <jaxws-types:system-handler-chain>
-                  <jaxws-types:preLogical>
-                      <jaxws-types:handler>
-                          <jaxws-types:handler-name>MAPAggregator</jaxws-types:handler-name>
-                          <jaxws-types:handler-class>org.objectweb.celtix.ws.addressing.MAPAggregator</jaxws-types:handler-class>
-                      </jaxws-types:handler>
-                  </jaxws-types:preLogical>
-                  <jaxws-types:postLogical/>
-                  <jaxws-types:preProtocol>
-                      <jaxws-types:handler>
-                          <jaxws-types:handler-name>MAPCodec</jaxws-types:handler-name>
-                          <jaxws-types:handler-class>org.objectweb.celtix.ws.addressing.soap.MAPCodec</jaxws-types:handler-class>
-                      </jaxws-types:handler>
-                  </jaxws-types:preProtocol>
-                  <jaxws-types:postProtocol/>
-              </jaxws-types:system-handler-chain>
-          </value>
-      </property>
-      <property name="handlerChain">
-          <value>
-              <jaxws-types:handler-chain>
-                  <jaxws-types:handler>
-                      <jaxws-types:handler-name>HeaderSnooper</jaxws-types:handler-name>
-                      <jaxws-types:handler-class>demo.ws_addressing.common.HeaderSnooper</jaxws-types:handler-class>
-                  </jaxws-types:handler>
-              </jaxws-types:handler-chain>
-          </value>
-      </property>
-  </bean>
- 
+    <bean id="cxf" class="org.apache.cxf.bus.spring.SpringBusImpl">
+        <property name="inInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+            </list>
+        </property>
+        <property name="outInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+            </list>
+        </property>
+        <property name="outFaultInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+            </list>
+        </property>
+    </bean> 
 </beans>

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/server.xml (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/celtix-server.xml)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/server.xml?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/celtix-server.xml&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/server.xml&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/celtix-server.xml (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/server.xml Tue Nov 14 09:13:44 2006
@@ -1,29 +1,56 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE beans SYSTEM 
-     "http://celtix.objectweb.org/configuration/spring/celtix-spring-beans.dtd">
+<!--
+  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"
+       xsi:schemaLocation="
+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"/>
 
-<beans xmlns:jaxws-types="http://celtix.objectweb.org/bus/jaxws/configuration/types">
+    <!-- We are adding the interceptors to the bus as we will have only one endpoint/service/bus. -->
 
-  <bean id="celtix.{http://objectweb.org/hello_world_soap_http}SOAPService" 
-        class="org.objectweb.celtix.bus.jaxws.endpoint_config.spring.EndpointConfigBean">
-      <property name="handlerChain">
-          <value>
-              <jaxws-types:handler-chain>
-                 <jaxws-types:handler>
-                      <jaxws-types:handler-name>MAPAggregator</jaxws-types:handler-name>
-                      <jaxws-types:handler-class>org.objectweb.celtix.ws.addressing.MAPAggregator</jaxws-types:handler-class>
-                  </jaxws-types:handler>
-                  <jaxws-types:handler>
-                      <jaxws-types:handler-name>MAPCodec</jaxws-types:handler-name>
-                      <jaxws-types:handler-class>org.objectweb.celtix.ws.addressing.soap.MAPCodec</jaxws-types:handler-class>
-                  </jaxws-types:handler>
-                  <jaxws-types:handler>
-                      <jaxws-types:handler-name>HeaderSnooper</jaxws-types:handler-name>
-                      <jaxws-types:handler-class>demo.ws_addressing.common.HeaderSnooper</jaxws-types:handler-class>
-                  </jaxws-types:handler>
-              </jaxws-types:handler-chain>              
-          </value>
-      </property>     
-  </bean>
- 
+    <bean id="cxf" class="org.apache.cxf.bus.spring.SpringBusImpl">
+        <property name="inInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+            </list>
+        </property>
+        <property name="inFaultInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+            </list>
+        </property>
+        <property name="outInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+            </list>
+        </property>
+        <property name="outFaultInterceptors">
+            <list>
+                <ref bean="mapAggregator"/>
+                <ref bean="mapCodec"/>
+            </list>
+        </property>
+    </bean> 
 </beans>

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/client/Client.java (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/client/Client.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/client/Client.java?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/client/Client.java&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/client/Client.java&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/client/Client.java (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/client/Client.java Tue Nov 14 09:13:44 2006
@@ -1,28 +1,52 @@
+/**
+ * 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.
+ */
+
 package demo.ws_addressing.client;
 
 import java.io.File;
 import java.lang.reflect.UndeclaredThrowableException;
+import java.util.ArrayList;
+import java.util.List;
 import java.util.Map;
 import javax.xml.namespace.QName;
 import javax.xml.ws.BindingProvider;
+import javax.xml.ws.handler.Handler;
+
+import demo.ws_addressing.common.HeaderSnooper;
 
-import org.objectweb.celtix.ws.addressing.AddressingBuilder;
-import org.objectweb.celtix.ws.addressing.AddressingProperties;
-import org.objectweb.celtix.ws.addressing.AttributedURIType;
-import org.objectweb.celtix.ws.addressing.ObjectFactory;
-import org.objectweb.celtix.ws.addressing.RelatesToType;
-
-import org.objectweb.hello_world_soap_http.Greeter;
-import org.objectweb.hello_world_soap_http.PingMeFault;
-import org.objectweb.hello_world_soap_http.SOAPService;
+import org.apache.cxf.ws.addressing.AddressingBuilder;
+import org.apache.cxf.ws.addressing.AddressingProperties;
+import org.apache.cxf.ws.addressing.AttributedURIType;
+import org.apache.cxf.ws.addressing.ObjectFactory;
+import org.apache.cxf.ws.addressing.RelatesToType;
 
-import static org.objectweb.celtix.ws.addressing.JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES;
+import org.apache.hello_world_soap_http.Greeter;
+import org.apache.hello_world_soap_http.PingMeFault;
+import org.apache.hello_world_soap_http.SOAPService;
+
+import static org.apache.cxf.ws.addressing.JAXWSAConstants.CLIENT_ADDRESSING_PROPERTIES;
 
 
 public final class Client {
     
     private static final QName SERVICE_NAME = 
-        new QName("http://objectweb.org/hello_world_soap_http", "SOAPService");
+        new QName("http://apache.org/hello_world_soap_http", "SOAPService");
     private static final ObjectFactory WSA_OBJECT_FACTORY = 
         new ObjectFactory();
     private static final String USER_NAME = System.getProperty("user.name");
@@ -42,6 +66,10 @@
             SOAPService service = new SOAPService(wsdl.toURL(), SERVICE_NAME);
             Greeter port = service.getSoapPort();
 
+            List<Handler> handlerChain = new ArrayList<Handler>();
+            handlerChain.add(new HeaderSnooper());
+            ((BindingProvider)port).getBinding().setHandlerChain(handlerChain);
+
             implicitPropagation(port);
 
             explicitPropagation(port);
@@ -120,9 +148,9 @@
 
         // set the RelatesTo property to the initial message ID, so that
         // the series of invocations are explicitly related
-        RelatesToType relatesTo = WSA_OBJECT_FACTORY.createRelatesToType();
-        relatesTo.setValue(messageID.getValue());
-        maps.setRelatesTo(relatesTo);
+        //RelatesToType relatesTo = WSA_OBJECT_FACTORY.createRelatesToType();
+        //relatesTo.setValue(messageID.getValue());
+        //maps.setRelatesTo(relatesTo);
 
         System.out.println("Invoking greetMe...");
         resp = port.greetMe(USER_NAME);
@@ -133,6 +161,6 @@
         System.out.println("No response from server as method is OneWay\n");
 
         // disassociate MAPs from request context
-        requestContext.put(CLIENT_ADDRESSING_PROPERTIES, null);
+        requestContext.remove(CLIENT_ADDRESSING_PROPERTIES);
     }
 }

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/HeaderSnooper.java Tue Nov 14 09:13:44 2006
@@ -1,3 +1,22 @@
+/**
+ * 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.
+ */
+
 package demo.ws_addressing.common;
 
 
@@ -16,8 +35,8 @@
 import javax.xml.ws.handler.soap.SOAPMessageContext;
 import static javax.xml.ws.handler.MessageContext.MESSAGE_OUTBOUND_PROPERTY;
 
-import org.objectweb.celtix.ws.addressing.AddressingBuilder;
-import org.objectweb.celtix.ws.addressing.AddressingConstants;
+import org.apache.cxf.ws.addressing.AddressingBuilder;
+import org.apache.cxf.ws.addressing.AddressingConstants;
 
 
 /**

Added: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/handler_chain.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/handler_chain.xml?view=auto&rev=474877
==============================================================================
--- incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/handler_chain.xml (added)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/handler_chain.xml Tue Nov 14 09:13:44 2006
@@ -0,0 +1,31 @@
+<?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.
+-->
+<handler-chains xmlns="http://java.sun.com/xml/ns/javaee" 
+xmlns:cfg="http://cxf.apache.org/configuration/cfg" 
+xmlns:jaxb="http://java.sun.com/xml/ns/jaxb" 
+xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" 
+xsi:schemaLocation="http://java.sun.com/xml/ns/javaee">
+    <handler-chain>
+        <handler>
+            <handler-name>HeaderSnooper</handler-name>
+            <handler-class>demo.ws_addressing.common.HeaderSnooper</handler-class>
+        </handler>
+    </handler-chain>
+</handler-chains>
\ No newline at end of file

Propchange: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/handler_chain.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/common/handler_chain.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/GreeterImpl.java Tue Nov 14 09:13:44 2006
@@ -1,13 +1,38 @@
+/**
+ * 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.
+ */
+
 package demo.ws_addressing.server;
 
 import java.util.logging.Logger;
-import org.objectweb.hello_world_soap_http.Greeter;
-import org.objectweb.hello_world_soap_http.PingMeFault;
-import org.objectweb.hello_world_soap_http.types.FaultDetail;
-
-@javax.jws.WebService(name = "Greeter", serviceName = "SOAPService", 
-                      targetNamespace = "http://objectweb.org/hello_world_soap_http", 
-                      wsdlLocation = "file:./wsdl/hello_world_addr.wsdl")
+
+import javax.jws.HandlerChain;
+import javax.jws.WebService;
+
+import org.apache.hello_world_soap_http.Greeter;
+import org.apache.hello_world_soap_http.PingMeFault;
+import org.apache.hello_world_soap_http.types.FaultDetail;
+
+@WebService(name = "Greeter",
+            serviceName = "SOAPService", 
+            targetNamespace = "http://apache.org/hello_world_soap_http", 
+            wsdlLocation = "file:./wsdl/hello_world_addr.wsdl")
+@HandlerChain(file = "../common/handler_chain.xml", name = "HandlerChain")
                   
 public class GreeterImpl implements Greeter {
 
@@ -15,7 +40,7 @@
         Logger.getLogger(GreeterImpl.class.getPackage().getName());
     
     /* (non-Javadoc)
-     * @see org.objectweb.hello_world_soap_http.Greeter#greetMe(java.lang.String)
+     * @see org.apache.hello_world_soap_http.Greeter#greetMe(java.lang.String)
      */
     public String greetMe(String me) {
         LOG.info("Executing operation greetMe");
@@ -25,7 +50,7 @@
     }
     
     /* (non-Javadoc)
-     * @see org.objectweb.hello_world_soap_http.Greeter#greetMeOneWay(java.lang.String)
+     * @see org.apache.hello_world_soap_http.Greeter#greetMeOneWay(java.lang.String)
      */
     public void greetMeOneWay(String me) {
         LOG.info("Executing operation greetMeOneWay");
@@ -34,7 +59,7 @@
     }
 
     /* (non-Javadoc)
-     * @see org.objectweb.hello_world_soap_http.Greeter#sayHi()
+     * @see org.apache.hello_world_soap_http.Greeter#sayHi()
      */
     public String sayHi() {
         LOG.info("Executing operation sayHi");

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/Server.java (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/server/Server.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/Server.java?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/server/Server.java&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/Server.java&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/src/demo/ws_addressing/server/Server.java (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/src/demo/ws_addressing/server/Server.java Tue Nov 14 09:13:44 2006
@@ -1,3 +1,22 @@
+/**
+ * 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.
+ */
+
 package demo.ws_addressing.server;
 
 import javax.xml.ws.Endpoint;

Copied: incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/wsdl/hello_world_addr.wsdl (from r438444, incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/wsdl/hello_world_addr.wsdl)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/wsdl/hello_world_addr.wsdl?view=diff&rev=474877&p1=incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/wsdl/hello_world_addr.wsdl&r1=438444&p2=incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/wsdl/hello_world_addr.wsdl&r2=474877
==============================================================================
--- incubator/cxf/branches/post_apache_integration/distribution/src/main/samples/ws_addressing/wsdl/hello_world_addr.wsdl (original)
+++ incubator/cxf/trunk/distribution/src/main/release/samples/ws_addressing/wsdl/hello_world_addr.wsdl Tue Nov 14 09:13:44 2006
@@ -1,13 +1,31 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<wsdl:definitions name="HelloWorld" targetNamespace="http://objectweb.org/hello_world_soap_http" 
+<!--
+  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.
+-->
+<wsdl:definitions name="HelloWorld" targetNamespace="http://apache.org/hello_world_soap_http" 
     xmlns="http://schemas.xmlsoap.org/wsdl/" 
     xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/" 
-    xmlns:tns="http://objectweb.org/hello_world_soap_http"
-    xmlns:x1="http://objectweb.org/hello_world_soap_http/types"
+    xmlns:tns="http://apache.org/hello_world_soap_http"
+    xmlns:x1="http://apache.org/hello_world_soap_http/types"
     xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/" 
     xmlns:xsd="http://www.w3.org/2001/XMLSchema">
     <wsdl:types>
-        <schema targetNamespace="http://objectweb.org/hello_world_soap_http/types" 
+        <schema targetNamespace="http://apache.org/hello_world_soap_http/types" 
             xmlns="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
             <element name="sayHi">
                 <complexType/>

Modified: incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/ReadHeadersInterceptor.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/ReadHeadersInterceptor.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/ReadHeadersInterceptor.java (original)
+++ incubator/cxf/trunk/rt/bindings/soap/src/main/java/org/apache/cxf/binding/soap/interceptor/ReadHeadersInterceptor.java Tue Nov 14 09:13:44 2006
@@ -99,9 +99,13 @@
                 
                 if (message.getVersion().getFault().equals(xmlReader.getName())) {
                     Endpoint ep = message.getExchange().get(Endpoint.class);
-                    message.getInterceptorChain().abort();
-                    if (ep.getInFaultObserver() != null) {
-                        ep.getInFaultObserver().onMessage(message);
+                    if (ep != null) {
+                        message.getInterceptorChain().abort();
+                        if (ep.getInFaultObserver() != null) {
+                            ep.getInFaultObserver().onMessage(message);
+                        }
+                    } else {
+                        message.getExchange().put("deferred.fault.observer.notification", Boolean.TRUE);
                     }
                 }
             }

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/endpoint/ClientImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/endpoint/ClientImpl.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/endpoint/ClientImpl.java (original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/endpoint/ClientImpl.java Tue Nov 14 09:13:44 2006
@@ -170,9 +170,11 @@
     }
 
     private Exception getException(Exchange exchange) {
-        if (exchange.getFaultMessage() != null) {
-            return exchange.getFaultMessage().getContent(Exception.class);
-        }
+        if (exchange.getInFaultMessage() != null) {
+            return exchange.getInFaultMessage().getContent(Exception.class);
+        } else if (exchange.getOutFaultMessage() != null) {
+            return exchange.getOutFaultMessage().getContent(Exception.class);
+        } 
         return null;
     }
 
@@ -335,6 +337,6 @@
 
     private boolean isPartialResponse(Message in) {
         return in.getContent(List.class) == null
-            && getException(in.getExchange()) == null;
+               && getException(in.getExchange()) == null;
     }
 }

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractFaultChainIntiatorObserver.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractFaultChainIntiatorObserver.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractFaultChainIntiatorObserver.java (original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/AbstractFaultChainIntiatorObserver.java Tue Nov 14 09:13:44 2006
@@ -45,13 +45,13 @@
 
     @SuppressWarnings("unchecked")
     public void onMessage(Message m) {
-        Message faultMessage = m.getExchange().getFaultMessage();
+        Message faultMessage = getFaultMessage(m);
         if (faultMessage == null) {
             faultMessage = new MessageImpl();
         }
         
         faultMessage = m.getExchange().get(Binding.class).createMessage(faultMessage);
-        m.getExchange().setFaultMessage(faultMessage);
+        setFaultMessage(m, faultMessage);
         m.putAll(faultMessage);
         faultMessage.putAll(m);
 
@@ -78,6 +78,8 @@
         }
     }
 
+    protected abstract boolean isOutboundObserver();
+
     protected abstract List<Phase> getPhases();
 
     protected void initializeInterceptors(Exchange ex, PhaseInterceptorChain chain) {
@@ -86,5 +88,19 @@
 
     public Bus getBus() {
         return bus;
+    }
+
+    private Message getFaultMessage(Message original) {
+        return isOutboundObserver()
+               ? original.getExchange().getOutFaultMessage()
+               : original.getExchange().getInFaultMessage();
+    }
+
+    private void setFaultMessage(Message original, Message fault) {
+        if (isOutboundObserver()) {
+            original.getExchange().setOutFaultMessage(fault);
+        } else {
+            original.getExchange().setInFaultMessage(fault);
+        }
     }
 }

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/ClientOutFaultObserver.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/ClientOutFaultObserver.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/ClientOutFaultObserver.java (original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/ClientOutFaultObserver.java Tue Nov 14 09:13:44 2006
@@ -43,4 +43,8 @@
     public void onMessage(Message m) {
         // do nothing for exception occured during client sending out request
     }
+
+    protected boolean isOutboundObserver() {
+        return true;
+    }
 }

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/InFaultChainInitiatorObserver.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/InFaultChainInitiatorObserver.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/InFaultChainInitiatorObserver.java (original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/InFaultChainInitiatorObserver.java Tue Nov 14 09:13:44 2006
@@ -45,4 +45,8 @@
     protected List<Phase> getPhases() {
         return getBus().getExtension(PhaseManager.class).getInPhases();
     }
+
+    protected boolean isOutboundObserver() {
+        return false;
+    }
 }

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutFaultChainInitiatorObserver.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutFaultChainInitiatorObserver.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutFaultChainInitiatorObserver.java (original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutFaultChainInitiatorObserver.java Tue Nov 14 09:13:44 2006
@@ -46,4 +46,7 @@
         return getBus().getExtension(PhaseManager.class).getOutPhases();
     }
 
+    protected boolean isOutboundObserver() {
+        return true;
+    }
 }

Modified: incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainSetupInterceptor.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainSetupInterceptor.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainSetupInterceptor.java (original)
+++ incubator/cxf/trunk/rt/core/src/main/java/org/apache/cxf/interceptor/OutgoingChainSetupInterceptor.java Tue Nov 14 09:13:44 2006
@@ -62,10 +62,10 @@
         }
         setUpContentType(outMessage);
 
-        Message faultMessage = message.getExchange().getFaultMessage();
+        Message faultMessage = message.getExchange().getOutFaultMessage();
         if (faultMessage == null) {
             faultMessage = ep.getBinding().createMessage();            
-            ex.setFaultMessage(faultMessage);
+            ex.setOutFaultMessage(faultMessage);
         }
 
         setUpContentType(faultMessage);

Modified: incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/AbstractJAXWSHandlerInterceptor.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/AbstractJAXWSHandlerInterceptor.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/AbstractJAXWSHandlerInterceptor.java (original)
+++ incubator/cxf/trunk/rt/frontend/jaxws/src/main/java/org/apache/cxf/jaxws/handler/AbstractJAXWSHandlerInterceptor.java Tue Nov 14 09:13:44 2006
@@ -37,7 +37,8 @@
     }
     
     boolean isOutbound(T message) {
-        return message == message.getExchange().getOutMessage();
+        return message == message.getExchange().getOutMessage()
+               || message == message.getExchange().getOutFaultMessage();
     }
     
     boolean isRequestor(T message) {

Modified: incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/ContextUtils.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/ContextUtils.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/ContextUtils.java (original)
+++ incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/ContextUtils.java Tue Nov 14 09:13:44 2006
@@ -106,16 +106,24 @@
     * @return true iff the message direction is outbound
     */
     public static boolean isOutbound(Message message) {
-        if (message == null) {
-            return false;
-        }
-        
         Exchange exchange = message.getExchange();
-        
         return message != null
                && exchange != null
-               && message == exchange.getOutMessage();
-        
+               && (message == exchange.getOutMessage()
+                   || message == exchange.getOutFaultMessage());
+    }
+
+   /**
+    * Determine if message is fault.
+    *
+    * @param message the current Message
+    * @return true iff the message is a fault
+    */
+    public static boolean isFault(Message message) {
+        return message != null
+               && message.getExchange() != null
+               && (message == message.getExchange().getInFaultMessage()
+                   || message == message.getExchange().getOutFaultMessage());
     }
 
    /**
@@ -309,6 +317,7 @@
                                       Message inMessage) {
         String namespaceURI = inMAPs.getNamespaceURI();
         if (!retrievePartialResponseSent(inMessage)) {
+            storePartialResponseSent(inMessage);
             Exchange exchange = inMessage.getExchange();
             Message fullResponse = exchange.getOutMessage();
             Endpoint endpoint = exchange.get(Endpoint.class);
@@ -319,7 +328,7 @@
             // and partial response messages (used to determine relatesTo etc.)
             propogateReceivedMAPs(inMAPs, partialResponse);
             propogateReceivedMAPs(inMAPs, fullResponse);
-            propogateReceivedMAPs(inMAPs, exchange.getFaultMessage());
+            propogateReceivedMAPs(inMAPs, exchange.getOutFaultMessage());
             
             try {
                 Destination target = inMessage.getDestination();

Modified: incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java (original)
+++ incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/MAPAggregator.java Tue Nov 14 09:13:44 2006
@@ -86,16 +86,15 @@
      * @param message the current message
      */
     public void handleMessage(Message message) {
-        mediate(message, false);
+        mediate(message, ContextUtils.isFault(message));
     }
 
     /**
-     * Invoked for fault processing.
+     * Invoked when unwinding normal interceptor chain when a fault occurred.
      *
      * @param message the current message
      */
     public void  handleFault(Message message) {
-        mediate(message, true);
     }
 
     /**
@@ -165,7 +164,7 @@
      * @param isFault true if a fault is being mediated
      * @return true if processing should continue on dispatch path 
      */
-    private boolean mediate(Message message, boolean isFault) {    
+    protected boolean mediate(Message message, boolean isFault) {    
         boolean continueProcessing = true;
         if (ContextUtils.isOutbound(message)) {
             if (usingAddressing(message)) {

Modified: incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/soap/MAPCodec.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/soap/MAPCodec.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/soap/MAPCodec.java (original)
+++ incubator/cxf/trunk/rt/ws/addr/src/main/java/org/apache/cxf/ws/addressing/soap/MAPCodec.java Tue Nov 14 09:13:44 2006
@@ -47,6 +47,7 @@
 import org.apache.cxf.binding.soap.SoapMessage;
 import org.apache.cxf.binding.soap.interceptor.AbstractSoapInterceptor;
 import org.apache.cxf.common.logging.LogUtils;
+import org.apache.cxf.endpoint.Endpoint;
 import org.apache.cxf.helpers.CastUtils;
 import org.apache.cxf.message.Exchange;
 import org.apache.cxf.phase.Phase;
@@ -85,6 +86,7 @@
     public MAPCodec() {
         super();
         setPhase(Phase.PRE_PROTOCOL);
+        addBefore("org.apache.cxf.jaxws.handler.soap.SOAPHandlerInterceptor");
         transformer = new VersionTransformer(this);
     } 
 
@@ -105,12 +107,11 @@
     }
 
     /**
-     * Invoked for fault processing.
+     * Invoked when unwinding normal interceptor chain when a fault occurred.
      *
      * @param message the messsage message
      */
     public void handleFault(SoapMessage message) {
-        mediate(message);
     }
 
     /**
@@ -454,7 +455,16 @@
                 uncorrelatedExchanges.get(maps.getRelatesTo().getValue());
             if (correlatedExchange != null) {
                 synchronized (correlatedExchange) {
+                    Exchange tmpExchange = message.getExchange();
                     message.setExchange(correlatedExchange);
+                    Endpoint endpoint = correlatedExchange.get(Endpoint.class);
+                    if (Boolean.TRUE.equals(tmpExchange.get("deferred.fault.observer.notification"))
+                        && endpoint != null) {
+                        message.getInterceptorChain().abort();
+                        if (endpoint.getInFaultObserver() != null) {
+                            endpoint.getInFaultObserver().onMessage(message);
+                        }
+                    }
                 }
             }
         }

Modified: incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/MAPAggregatorTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/MAPAggregatorTest.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/MAPAggregatorTest.java (original)
+++ incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/MAPAggregatorTest.java Tue Nov 14 09:13:44 2006
@@ -82,7 +82,7 @@
     public void testRequestorOutboundUsingAddressingMAPsInContext() 
         throws Exception {
         Message message = setUpMessage(true, true, false, true, true);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, true, true, true);
     }
@@ -90,7 +90,7 @@
     public void testRequestorOutboundUsingAddressingMAPsInContextZeroLengthAction() 
         throws Exception {
         Message message = setUpMessage(true, true, false, true, true, true);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, true, true, true);
     }
@@ -98,7 +98,7 @@
     public void testRequestorOutboundUsingAddressingMAPsInContextFault() 
         throws Exception {
         Message message = setUpMessage(true, true, false, true, true);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, true, true, true);
     }
@@ -106,7 +106,7 @@
     public void testRequestorOutboundUsingAddressingNoMAPsInContext() 
         throws Exception {
         Message message = setUpMessage(true, true, false, true, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, true, true, true);
     }
@@ -114,14 +114,14 @@
     public void testRequestorOutboundUsingAddressingNoMAPsInContextFault() 
         throws Exception {
         Message message = setUpMessage(true, true, false, true, false);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, true, true, true);
     }
 
     public void testRequestorOutboundNotUsingAddressing() throws Exception {
         Message message = setUpMessage(true, true, false, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, true, true, false);
     }
@@ -129,7 +129,7 @@
     public void testRequestorOutboundNotUsingAddressingFault() 
         throws Exception {
         Message message = setUpMessage(true, true, false, false);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, true, true, false);
     }
@@ -137,7 +137,7 @@
     public void testRequestorOutboundOnewayUsingAddressingMAPsInContext() 
         throws Exception {
         Message message = setUpMessage(true, true, true, true, true);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, true, true, true);
     }
@@ -145,7 +145,7 @@
     public void testRequestorOutboundOnewayUsingAddressingMAPsInContextFault() 
         throws Exception {
         Message message = setUpMessage(true, true, true, true, true);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, true, true, true);
     }
@@ -153,7 +153,7 @@
     public void testRequestorOutboundOnewayUsingAddressingNoMAPsInContext() 
         throws Exception {
         Message message = setUpMessage(true, true, true, true, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, true, true, true);
     }
@@ -161,14 +161,14 @@
     public void testRequestorOutboundOnewayUsingAddressingNoMAPsInContextFault() 
         throws Exception {
         Message message = setUpMessage(true, true, true, true, false);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, true, true, true);
     }
 
     public void testRequestorOutboundOnewayNotUsingAddressing() throws Exception {
         Message message = setUpMessage(true, true, true, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, true, true, false);
     }
@@ -177,14 +177,14 @@
     public void testRequestorOutboundOnewayNotUsingAddressingFault() 
         throws Exception {
         Message message = setUpMessage(true, true, true, false);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, true, true, false);
     }
 
     public void testResponderInboundValidMAPs() throws Exception {
         Message message = setUpMessage(false, false, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, false, false, false);
     }
@@ -192,7 +192,7 @@
     public void testResponderInboundDecoupled() throws Exception {
         Message message = 
             setUpMessage(false, false, false, true, false, true);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, false, false, true);
     }
@@ -200,14 +200,14 @@
     public void testResponderInboundOneway() throws Exception {
         Message message = 
             setUpMessage(false, false, true, true, false, true);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, false, false, true);
     }
 
     public void testResponderInboundValidMAPsFault() throws Exception {
         Message message = setUpMessage(false, false, false);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, false, false, true);
     }
@@ -215,7 +215,7 @@
     public void testResponderInboundInvalidMAPs() throws Exception {
         aggregator.messageIDs.put("urn:uuid:12345", "urn:uuid:12345");
         Message message = setUpMessage(false, false, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, false, false, false /*check*/);
     }
@@ -223,14 +223,14 @@
     public void testResponderInboundInvalidMAPsFault() throws Exception {
         aggregator.messageIDs.put("urn:uuid:12345", "urn:uuid:12345");
         Message message = setUpMessage(false, false, false);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, false, false, false /*check*/);
     }
 
     public void testResponderOutbound() throws Exception {
         Message message = setUpMessage(false, true, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, false, true, true);
     }
@@ -238,7 +238,7 @@
     public void testResponderOutboundZeroLengthAction() throws Exception {
         Message message = 
             setUpMessage(false, true, false, false, false, false, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, false, true, true);
     }
@@ -252,21 +252,21 @@
                                                       true,
                                                       false,
                                                       true});
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, false, true, true);
     }
 
     public void testRequestorInbound() throws Exception {
         Message message = setUpMessage(true, false, false);
-        aggregator.handleMessage(message);
+        aggregator.mediate(message, false);
         control.verify();
         verifyMessage(message, true, false, false /*check*/);
     }
 
     public void testRequestorInboundFault() throws Exception {
         Message message = setUpMessage(true, false, false);
-        aggregator.handleFault(message);
+        aggregator.mediate(message, true);
         control.verify();
         verifyMessage(message, true, false, false /*check*/);
     }

Modified: incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/soap/MAPCodecTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/soap/MAPCodecTest.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/soap/MAPCodecTest.java (original)
+++ incubator/cxf/trunk/rt/ws/addr/src/test/java/org/apache/cxf/ws/addressing/soap/MAPCodecTest.java Tue Nov 14 09:13:44 2006
@@ -114,13 +114,6 @@
         control.verify();
         verifyMessage(message, true, true, true);
     }
-
-    public void testRequestorOutboundFault() throws Exception {
-        SoapMessage message = setUpMessage(true, true);
-        codec.handleFault(message);
-        control.verify();
-        verifyMessage(message, true, true, true);
-    }
     
     public void testRequestorOutboundPreExistingSOAPAction() throws Exception {
         SoapMessage message = setUpMessage(true, true, false, true);
@@ -146,13 +139,6 @@
         verifyMessage(message, false, false, true);
     }
 
-    public void testResponderInboundFault() throws Exception {
-        SoapMessage message = setUpMessage(false, false);
-        codec.handleFault(message);
-        control.verify();
-        verifyMessage(message, false, false, true);
-    }
-
     public void testResponderOutbound() throws Exception {
         SoapMessage message = setUpMessage(false, true);
         codec.handleMessage(message);
@@ -182,27 +168,6 @@
         control.verify();
         verifyMessage(message, false, true, true);
     }
-
-    public void testResponderOutboundFault() throws Exception {
-        SoapMessage message = setUpMessage(false, true);
-        codec.handleFault(message);
-        control.verify();
-        verifyMessage(message, false, true, true);
-    }
-
-    public void testResponderOutboundFaultInvalidMAP() throws Exception {
-        SoapMessage message = setUpMessage(false, true, true);
-        try {
-            codec.handleFault(message);
-            fail("expected SOAPFaultException on invalid MAP");
-        } catch (SOAPFaultException sfe) {
-            assertEquals("unexpected fault string",
-                         "Duplicate Message ID urn:uuid:12345",
-                         sfe.getFault().getFaultString());
-        }
-        control.verify();
-        verifyMessage(message, false, true, true);
-    }
     
     public void testResponderOutboundPreExistingSOAPAction() throws Exception {
         SoapMessage message = setUpMessage(false, true, false, true);
@@ -224,13 +189,6 @@
     public void testRequestorInbound() throws Exception {
         SoapMessage message = setUpMessage(true, false);
         codec.handleMessage(message);
-        control.verify();
-        verifyMessage(message, true, false, true);
-    }
-
-    public void testRequestorInboundFault() throws Exception {
-        SoapMessage message = setUpMessage(true, false);
-        codec.handleFault(message);
         control.verify();
         verifyMessage(message, true, false, true);
     }

Modified: incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/AbstractRMInterceptor.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/AbstractRMInterceptor.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/AbstractRMInterceptor.java (original)
+++ incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/AbstractRMInterceptor.java Tue Nov 14 09:13:44 2006
@@ -114,8 +114,10 @@
     }
     
     private Exception getException(Exchange exchange) {
-        if (exchange.getFaultMessage() != null) {
-            return exchange.getFaultMessage().getContent(Exception.class);
+        if (exchange.getOutFaultMessage() != null) {
+            return exchange.getOutFaultMessage().getContent(Exception.class);
+        } else if (exchange.getInFaultMessage() != null) {
+            return exchange.getInFaultMessage().getContent(Exception.class);
         }
         return null;
     }

Modified: incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMContextUtils.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMContextUtils.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMContextUtils.java (original)
+++ incubator/cxf/trunk/rt/ws/rm/src/main/java/org/apache/cxf/ws/rm/RMContextUtils.java Tue Nov 14 09:13:44 2006
@@ -77,7 +77,7 @@
             return message.getExchange().getInMessage() != null;
         } else {
             return message.getExchange().getOutMessage() == null 
-                && message.getExchange().getFaultMessage() == null;
+                && message.getExchange().getOutFaultMessage() == null;
         }
     }
     

Modified: incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMManagerTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMManagerTest.java?view=diff&rev=474877&r1=474876&r2=474877
==============================================================================
--- incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMManagerTest.java (original)
+++ incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMManagerTest.java Tue Nov 14 09:13:44 2006
@@ -185,7 +185,7 @@
         EasyMock.expect(message.getExchange()).andReturn(exchange).anyTimes();
         EasyMock.expect(exchange.getOutMessage()).andReturn(message).anyTimes();
         EasyMock.expect(exchange.getInMessage()).andReturn(null).anyTimes();
-        EasyMock.expect(exchange.getFaultMessage()).andReturn(null).anyTimes();
+        EasyMock.expect(exchange.getOutFaultMessage()).andReturn(null).anyTimes();
         Conduit conduit = control.createMock(Conduit.class);
         EasyMock.expect(exchange.getConduit()).andReturn(conduit).anyTimes();
         EasyMock.expect(conduit.getBackChannel()).andReturn(null).anyTimes();



Mime
View raw message