cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From andreasm...@apache.org
Subject svn commit: r526120 [2/2] - in /incubator/cxf/trunk: api/src/main/java/org/apache/cxf/message/ api/src/main/java/org/apache/cxf/ws/policy/ api/src/main/java/org/apache/cxf/ws/policy/builder/jaxb/ api/src/test/java/org/apache/cxf/ws/policy/ api/src/test...
Date Fri, 06 Apr 2007 11:21:49 GMT
Modified: incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMEndpointTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMEndpointTest.java?view=diff&rev=526120&r1=526119&r2=526120
==============================================================================
--- incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMEndpointTest.java (original)
+++ incubator/cxf/trunk/rt/ws/rm/src/test/java/org/apache/cxf/ws/rm/RMEndpointTest.java Fri
Apr  6 04:21:45 2007
@@ -206,6 +206,17 @@
     }
     
     @Test
+    public void testSetPoliciesEngineDisabled() {
+        Bus bus = control.createMock(Bus.class);
+        EasyMock.expect(manager.getBus()).andReturn(bus);
+        PolicyEngine pe = control.createMock(PolicyEngine.class);
+        EasyMock.expect(bus.getExtension(PolicyEngine.class)).andReturn(pe);
+        EasyMock.expect(pe.isEnabled()).andReturn(false);
+        control.replay();
+        rme.setPolicies();   
+    }
+    
+    @Test
     public void testSetPolicies() throws NoSuchMethodException {
         Method m = RMEndpoint.class.getDeclaredMethod("getEndpoint", new Class[] {});
         rme = control.createMock(RMEndpoint.class, new Method[] {m});
@@ -219,6 +230,7 @@
         EasyMock.expect(manager.getBus()).andReturn(bus).times(2);
         PolicyEngine pe = control.createMock(PolicyEngine.class);
         EasyMock.expect(bus.getExtension(PolicyEngine.class)).andReturn(pe);
+        EasyMock.expect(pe.isEnabled()).andReturn(true);
         PolicyInterceptorProviderRegistry reg = control.createMock(PolicyInterceptorProviderRegistry.class);
         EasyMock.expect(bus.getExtension(PolicyInterceptorProviderRegistry.class)).andReturn(reg);
         EndpointInfo aei = control.createMock(EndpointInfo.class);

Copied: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/AddressingPolicyTest.java
(from r524739, incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/AddressingPolicyClientServerTest.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/AddressingPolicyTest.java?view=diff&rev=526120&p1=incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/AddressingPolicyClientServerTest.java&r1=524739&p2=incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/AddressingPolicyTest.java&r2=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/AddressingPolicyClientServerTest.java
(original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/AddressingPolicyTest.java
Fri Apr  6 04:21:45 2007
@@ -41,9 +41,9 @@
  * Tests the use of the WS-Policy Framework to automatically engage WS-Addressing and
  * WS-RM in response to Policies defined for the endpoint via an external policy attachment.
  */
-public class AddressingPolicyClientServerTest extends AbstractBusClientServerTestBase {
+public class AddressingPolicyTest extends AbstractBusClientServerTestBase {
 
-    private static final Logger LOG = Logger.getLogger(AddressingPolicyClientServerTest.class.getName());
+    private static final Logger LOG = Logger.getLogger(AddressingPolicyTest.class.getName());
 
     public static class Server extends AbstractBusTestServerBase {
     

Added: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HTTPClientPolicyTest.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HTTPClientPolicyTest.java?view=auto&rev=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HTTPClientPolicyTest.java
(added)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HTTPClientPolicyTest.java
Fri Apr  6 04:21:45 2007
@@ -0,0 +1,156 @@
+/**
+ * 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 org.apache.cxf.systest.ws.policy;
+
+import java.net.SocketTimeoutException;
+import java.net.URL;
+import java.util.logging.Logger;
+
+import javax.xml.namespace.QName;
+import javax.xml.ws.Endpoint;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.BusFactory;
+import org.apache.cxf.bus.spring.SpringBusFactory;
+import org.apache.cxf.greeter_control.BasicGreeterService;
+import org.apache.cxf.greeter_control.Greeter;
+import org.apache.cxf.greeter_control.PingMeFault;
+import org.apache.cxf.interceptor.LoggingInInterceptor;
+import org.apache.cxf.interceptor.LoggingOutInterceptor;
+import org.apache.cxf.testutil.common.AbstractBusClientServerTestBase;
+import org.apache.cxf.testutil.common.AbstractBusTestServerBase;
+import org.apache.cxf.ws.policy.PolicyException;
+import org.junit.BeforeClass;
+import org.junit.Test;
+
+
+/**
+ * Tests the use of the WS-Policy Framework to determine the behaviour of the HTTP client
+ * by policies including the HTTPClientPolicy assertion attached to different subjects
+ * of the contract (endpoint, operation, binding, messager).
+ * The server in this test is not policy aware.
+ * Neither client nor server do have addressing interceptors installed: there are no addressing
+ * assertions that would trigger the installation of the interceptors on the client side.
The use
+ * of the DecoupledEndpoint attribute in the HTTPClientPolicy assertions is merely for illustrating
+ * the use of multiple compatible or incompatible assertions.
+ */
+public class HTTPClientPolicyTest extends AbstractBusClientServerTestBase {
+
+    private static final Logger LOG = Logger.getLogger(HTTPClientPolicyTest.class.getName());
+
+    public static class Server extends AbstractBusTestServerBase {
+   
+        protected void run()  {            
+            SpringBusFactory bf = new SpringBusFactory();
+            Bus bus = bf.createBus();
+            BusFactory.setDefaultBus(bus);
+            LoggingInInterceptor in = new LoggingInInterceptor();
+            LoggingOutInterceptor out = new LoggingOutInterceptor();           
+            bus.getInInterceptors().add(in);
+            bus.getOutInterceptors().add(out);                    
+            bus.getOutFaultInterceptors().add(out);
+            
+            HttpGreeterImpl implementor = new HttpGreeterImpl();
+            implementor.setThrowAlways(true);
+            String address = "http://localhost:9020/SoapContext/GreeterPort";
+            Endpoint.publish(address, implementor);
+            LOG.info("Published greeter endpoint.");            
+        }
+        
+
+        public static void main(String[] args) {
+            try { 
+                Server s = new Server(); 
+                s.start();
+            } catch (Exception ex) {
+                ex.printStackTrace();
+                System.exit(-1);
+            } finally { 
+                System.out.println("done!");
+            }
+        }
+    }    
+
+    @BeforeClass
+    public static void startServers() throws Exception {
+        assertTrue("server did not launch correctly", launchServer(Server.class));
+    }
+         
+    @Test
+    public void testUsingAddressing() throws Exception {
+        SpringBusFactory bf = new SpringBusFactory();
+        bus = bf.createBus("org/apache/cxf/systest/ws/policy/http.xml");
+        BusFactory.setDefaultBus(bus);
+        LoggingInInterceptor in = new LoggingInInterceptor();
+        bus.getInInterceptors().add(in);
+        bus.getInFaultInterceptors().add(in);
+        bus.getInInterceptors().add(new PolicyLoggingInterceptor(false));
+        bus.getInFaultInterceptors().add(new PolicyLoggingInterceptor(false));
+        LoggingOutInterceptor out = new LoggingOutInterceptor();
+        bus.getOutInterceptors().add(out);
+        bus.getOutFaultInterceptors().add(out);
+        bus.getOutInterceptors().add(new PolicyLoggingInterceptor(true));
+        
+        // use a client wsdl with policies attached to endpoint, operation and message subjects
+        
+        URL url = HTTPClientPolicyTest.class.getResource("http_client_greeter.wsdl");
+        
+        BasicGreeterService gs = new BasicGreeterService(url, 
+            new QName("http://cxf.apache.org/greeter_control", "BasicGreeterService"));
+        final Greeter greeter = gs.getGreeterPort();
+        LOG.fine("Created greeter client.");
+        
+        // sayHi - this operation has message policies that are incompatible with
+        // the endpoint policies
+       
+        try {
+            greeter.sayHi();
+            fail("Did not receive expected PolicyException.");
+        } catch (PolicyException ex) {
+            assertEquals("INCOMPATIBLE_HTTPCLIENTPOLICY_ASSERTIONS", ex.getCode());
+        }
+
+        // greetMeOneWay - no message or operation policies
+
+        greeter.greetMeOneWay("CXF");
+
+        // greetMe - operation policy specifies receive timeout and should cause every 
+        // other invocation to fail
+
+        assertEquals("CXF", greeter.greetMe("cxf")); 
+
+        try {
+            greeter.greetMe("cxf");
+        } catch (Exception ex) {
+            assertTrue(ex.getCause() instanceof SocketTimeoutException);
+        }
+     
+        // pingMe - policy attached to binding operation fault should have no effect
+
+        try {
+            greeter.pingMe();
+            fail("Expected PingMeFault not thrown.");
+        } catch (PingMeFault ex) {
+            assertEquals(2, (int)ex.getFaultInfo().getMajor());
+            assertEquals(1, (int)ex.getFaultInfo().getMinor());
+        } 
+
+    }
+}

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HTTPClientPolicyTest.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HTTPClientPolicyTest.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HttpGreeterImpl.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HttpGreeterImpl.java?view=auto&rev=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HttpGreeterImpl.java
(added)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HttpGreeterImpl.java
Fri Apr  6 04:21:45 2007
@@ -0,0 +1,49 @@
+/**
+ * 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 org.apache.cxf.systest.ws.policy;
+
+import javax.jws.WebService;
+
+import org.apache.cxf.greeter_control.AbstractGreeterImpl;
+
+/**
+ * 
+ */
+
+@WebService(serviceName = "BasicGreeterService",
+            portName = "GreeterPort",
+            endpointInterface = "org.apache.cxf.greeter_control.Greeter",
+            targetNamespace = "http://cxf.apache.org/greeter_control")
+public class HttpGreeterImpl extends AbstractGreeterImpl {
+
+    private int greetMeCount;
+    
+    @Override
+    public String greetMe(String arg0) {
+        if (0 == greetMeCount % 2) {
+            setDelay(0);
+        } else {
+            setDelay(2000);
+        }   
+        greetMeCount++;
+        return super.greetMe(arg0);
+    }
+    
+}

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HttpGreeterImpl.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/HttpGreeterImpl.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Added: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/PolicyLoggingInterceptor.java
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/PolicyLoggingInterceptor.java?view=auto&rev=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/PolicyLoggingInterceptor.java
(added)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/PolicyLoggingInterceptor.java
Fri Apr  6 04:21:45 2007
@@ -0,0 +1,85 @@
+/**
+ * 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 org.apache.cxf.systest.ws.policy;
+
+import java.util.Collection;
+import java.util.logging.Logger;
+
+import org.apache.cxf.interceptor.Fault;
+import org.apache.cxf.message.Message;
+import org.apache.cxf.phase.AbstractPhaseInterceptor;
+import org.apache.cxf.phase.Phase;
+import org.apache.cxf.service.model.OperationInfo;
+import org.apache.cxf.transport.http.policy.PolicyUtils;
+import org.apache.cxf.transports.http.configuration.HTTPClientPolicy;
+import org.apache.cxf.ws.policy.AssertionInfo;
+import org.apache.cxf.ws.policy.AssertionInfoMap;
+import org.apache.cxf.ws.policy.builder.jaxb.JaxbAssertion;
+
+public class PolicyLoggingInterceptor extends AbstractPhaseInterceptor {
+
+    private static final Logger LOG = Logger.getLogger(PolicyLoggingInterceptor.class.getName());
+    
+    private boolean outbound;
+    
+    PolicyLoggingInterceptor(boolean o) {
+        outbound = o;
+        setPhase(Phase.PRE_LOGICAL);
+        /*
+        if (outbound) {
+            setPhase(Phase.POST_STREAM);
+            addBefore(PolicyVerificationOutInterceptor.class.getName());
+        } else {
+            setPhase(Phase.PRE_INVOKE);
+            addBefore(PolicyVerificationInInterceptor.class.getName());
+        }
+        */
+    }
+    
+    public void handleMessage(Message message) throws Fault {
+        StringBuffer buf = new StringBuffer();
+        String nl = System.getProperty("line.separator");
+        buf.append(outbound ? "Outbound " : "Inbound ");
+        buf.append("message for operation: " + message.getExchange().get(OperationInfo.class).getName());
+        buf.append(nl);
+        buf.append("Policies:");
+        buf.append(nl);
+        AssertionInfoMap aim = message.get(AssertionInfoMap.class);
+        if (null != aim) {
+            for (Collection<AssertionInfo> ais : aim.values()) {
+                for (AssertionInfo ai : ais) {
+                    JaxbAssertion<HTTPClientPolicy> cp = JaxbAssertion.cast((JaxbAssertion)ai.getAssertion(),
+                                                                            HTTPClientPolicy.class);
+                    buf.append(cp);
+                    buf.append(nl);
+                    buf.append("    data: ");
+                    buf.append(PolicyUtils.toString(cp.getData()));
+                    buf.append(nl);
+                    buf.append("    asserted: ");
+                    buf.append(ai.isAsserted());
+                    buf.append(nl);
+                }
+            }
+        }
+        LOG.fine(buf.toString());
+        
+    }
+
+}

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/PolicyLoggingInterceptor.java
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/PolicyLoggingInterceptor.java
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Copied: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyTest.java
(from r524739, incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyClientServerTest.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyTest.java?view=diff&rev=526120&p1=incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyClientServerTest.java&r1=524739&p2=incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyTest.java&r2=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyClientServerTest.java
(original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyTest.java
Fri Apr  6 04:21:45 2007
@@ -44,12 +44,12 @@
 
 
 /**
- * Tests the use of the WS-Policy Framework to automatically engage WS-Addressing and
- * WS-RM in response to Policies defined for the endpoint via an external policy attachment.
+ * Tests the use of the WS-Policy Framework to automatically engage WS-RM
+ * in response to Policies defined for the endpoint via an external policy attachment.
  */
-public class RMPolicyClientServerTest extends AbstractBusClientServerTestBase {
+public class RMPolicyTest extends AbstractBusClientServerTestBase {
 
-    private static final Logger LOG = Logger.getLogger(RMPolicyClientServerTest.class.getName());
+    private static final Logger LOG = Logger.getLogger(RMPolicyTest.class.getName());
     private static final String GREETMEONEWAY_ACTION = null;
     private static final String GREETME_ACTION = null;
     private static final String GREETME_RESPONSE_ACTION = null;

Copied: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyWsdlTest.java
(from r524739, incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMWsdlPolicyClientServerTest.java)
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyWsdlTest.java?view=diff&rev=526120&p1=incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMWsdlPolicyClientServerTest.java&r1=524739&p2=incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyWsdlTest.java&r2=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMWsdlPolicyClientServerTest.java
(original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/RMPolicyWsdlTest.java
Fri Apr  6 04:21:45 2007
@@ -44,12 +44,12 @@
 
 
 /**
- * Tests the use of the WS-Policy Framework to automatically engage WS-Addressing and
- * WS-RM in response to Policies defined for the endpoint via an external policy attachment.
+ * Tests the use of the WS-Policy Framework to automatically engage WS-RM
+ * in response to Policies defined for the endpoint via an direct attachment to the wsdl.
  */
-public class RMWsdlPolicyClientServerTest extends AbstractBusClientServerTestBase {
+public class RMPolicyWsdlTest extends AbstractBusClientServerTestBase {
 
-    private static final Logger LOG = Logger.getLogger(RMWsdlPolicyClientServerTest.class.getName());
+    private static final Logger LOG = Logger.getLogger(RMPolicyWsdlTest.class.getName());
     private static final String GREETMEONEWAY_ACTION = null;
     private static final String GREETME_ACTION = null;
     private static final String GREETME_RESPONSE_ACTION = null;

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr.xml?view=diff&rev=526120&r1=526119&r2=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr.xml (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/addr.xml Fri
Apr  6 04:21:45 2007
@@ -30,39 +30,12 @@
 
     <bean id="org.apache.cxf.ws.policy.PolicyEngine" class="org.apache.cxf.ws.policy.spring.InitializingPolicyEngine">
         <property name="bus" ref="cxf"/>
-        <property name="registerInterceptors" value="true"/>
+        <property name="enabled" value="true"/>
     </bean>
 
     <bean class="org.apache.cxf.ws.policy.attachment.external.ExternalAttachmentProvider">
         <constructor-arg ref="cxf"/>
         <property name="location" value="org/apache/cxf/systest/ws/policy/addr-external.xml"/>
     </bean>
-
-    <!--
-    <bean id="mapAggregator" class="org.apache.cxf.ws.addressing.MAPAggregator"/>
-    <bean id="mapCodec" class="org.apache.cxf.ws.addressing.soap.MAPCodec"/>
-
-    <bean id="cxf" class="org.apache.cxf.bus.CXFBusImpl">
-        <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>

Added: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http.xml?view=auto&rev=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http.xml (added)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http.xml Fri
Apr  6 04:21:45 2007
@@ -0,0 +1,32 @@
+<?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:http="http://cxf.apache.org/transports/http/configuration"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xsi:schemaLocation="
+http://cxf.apache.org/transports/http/configuration http://cxf.apache.org/schema/transports/http.xsd
+http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+    <bean id="org.apache.cxf.ws.policy.PolicyEngine" class="org.apache.cxf.ws.policy.spring.InitializingPolicyEngine">
+        <property name="bus" ref="cxf"/>
+        <property name="enabled" value="true"/>
+    </bean>
+
+</beans>
\ No newline at end of file

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: 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=auto&rev=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl
(added)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl
Fri Apr  6 04:21:45 2007
@@ -0,0 +1,202 @@
+<?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.
+-->
+<wsdl:definitions xmlns="http://schemas.xmlsoap.org/wsdl/"
+    xmlns:soap="http://schemas.xmlsoap.org/wsdl/soap/"
+    xmlns:tns="http://cxf.apache.org/greeter_control"
+    xmlns:x1="http://cxf.apache.org/greeter_control/types"
+    xmlns:wsdl="http://schemas.xmlsoap.org/wsdl/"
+    xmlns:xsd="http://www.w3.org/2001/XMLSchema"
+    targetNamespace="http://cxf.apache.org/greeter_control" name="HelloWorld">
+    <wsdl:types>
+        <schema targetNamespace="http://cxf.apache.org/greeter_control/types" 
+            xmlns="http://www.w3.org/2001/XMLSchema" elementFormDefault="qualified">
+            <element name="sayHi">
+                <complexType/>
+            </element>
+            <element name="sayHiResponse">
+                <complexType>
+                    <sequence>
+                        <element name="responseType" type="xsd:string"/>
+                    </sequence>
+                </complexType>
+            </element>
+            <element name="greetMe">
+                <complexType>
+                    <sequence>
+                        <element name="requestType" type="xsd:string"/>
+                    </sequence>
+                </complexType>
+            </element>
+            <element name="greetMeResponse">
+                <complexType>
+                    <sequence>
+                        <element name="responseType" type="xsd:string"/>
+                    </sequence>
+                </complexType>
+            </element>
+            <element name="greetMeOneWay">
+                <complexType>
+                    <sequence>
+                        <element name="requestType" type="xsd:string"/>
+                    </sequence>
+                </complexType>
+            </element>
+            <element name="pingMe">
+                <complexType/>
+            </element>
+            <element name="pingMeResponse">
+                <complexType/>
+            </element>
+            <element name="faultDetail">
+                <complexType>
+                    <sequence>
+                        <element name="minor" type="xsd:short"/>
+                        <element name="major" type="xsd:short"/>
+                    </sequence>
+                </complexType>
+            </element>
+        </schema>
+    </wsdl:types>
+
+   
+   <wsdl:message name="sayHiRequest">
+        <wsdl:part element="x1:sayHi" name="in"/>
+    </wsdl:message>
+    <wsdl:message name="sayHiResponse">
+        <wsdl:part element="x1:sayHiResponse" name="out"/>
+    </wsdl:message>
+    <wsdl:message name="greetMeRequest">
+        <wsdl:part element="x1:greetMe" name="in"/>
+    </wsdl:message>
+    <wsdl:message name="greetMeResponse">
+        <wsdl:part element="x1:greetMeResponse" name="out"/>
+    </wsdl:message>
+    <wsdl:message name="greetMeOneWayRequest">
+        <wsdl:part element="x1:greetMeOneWay" name="in"/>
+    </wsdl:message>
+    <wsdl:message name="pingMeRequest">
+    <wsdl:part name="in" element="x1:pingMe"/>
+    </wsdl:message>
+    <wsdl:message name="pingMeResponse">
+        <wsdl:part name="out" element="x1:pingMeResponse"/>
+    </wsdl:message>        
+    <wsdl:message name="pingMeFault">
+        <wsdl:part name="faultDetail" element="x1:faultDetail"/>
+    </wsdl:message> 
+    
+    <wsdl:portType name="Greeter">
+        <wsdl:operation name="sayHi">
+            <wsp:Policy xmlns:wsp="http://www.w3.org/2006/07/ws-policy">
+                <http-conf:client xmlns:http-conf="http://cxf.apache.org/transports/http/configuration"
+                    DecoupledEndpoint="http://localhost:9998/decoupled_endpoint"/>
+            </wsp:Policy>
+            <wsdl:input message="tns:sayHiRequest" name="sayHiRequest"/>
+            <wsdl:output message="tns:sayHiResponse" name="sayHiResponse"/>
+        </wsdl:operation>
+        
+        <wsdl:operation name="greetMe">
+            <wsdl:input message="tns:greetMeRequest" name="greetMeRequest"/>
+            <wsdl:output message="tns:greetMeResponse" name="greetMeResponse"/>
+        </wsdl:operation>
+        
+        <wsdl:operation name="greetMeOneWay">
+            <wsdl:input message="tns:greetMeOneWayRequest" name="greetMeOneWayRequest"/>
+        </wsdl:operation>
+
+        <wsdl:operation name="pingMe">
+            <wsdl:input name="pingMeRequest" message="tns:pingMeRequest"/>
+            <wsdl:output name="pingMeResponse" message="tns:pingMeResponse"/>
+            <wsdl:fault name="pingMeFault" message="tns:pingMeFault"/>            
+        </wsdl:operation> 
+    </wsdl:portType>
+
+    <wsdl:binding name="GreeterSOAPBinding" type="tns:Greeter">
+        <soap:binding style="document" transport="http://schemas.xmlsoap.org/soap/http"/>
+        
+        <wsdl:operation name="sayHi">
+            <soap:operation soapAction="" style="document"/>
+            <wsdl:input name="sayHiRequest">
+                <soap:body use="literal"/>
+            </wsdl:input>
+            <wsdl:output name="sayHiResponse">
+                <soap:body use="literal"/>
+            </wsdl:output>
+        </wsdl:operation>
+        
+        <wsdl:operation name="greetMe">
+            <wsp:Policy xmlns:wsp="http://www.w3.org/2006/07/ws-policy">
+                <http-conf:client xmlns:http-conf="http://cxf.apache.org/transports/http/configuration"
+                    ReceiveTimeout="2000"/>
+            </wsp:Policy>
+            <soap:operation soapAction="" style="document"/>
+            <wsdl:input name="greetMeRequest">
+                <soap:body use="literal"/>
+            </wsdl:input>
+            <wsdl:output name="greetMeResponse">
+                <soap:body use="literal"/>
+            </wsdl:output>
+        </wsdl:operation>
+        
+        <wsdl:operation name="greetMeOneWay">
+            <soap:operation soapAction="" style="document"/>
+            <wsdl:input name="greetMeOneWayRequest">
+                <soap:body use="literal"/>
+            </wsdl:input>
+        </wsdl:operation>
+
+            <wsdl:operation name="pingMe">
+            <soap:operation style="document"/>
+            <wsdl:input>
+                <soap:body use="literal"/>
+            </wsdl:input>
+            <wsdl:output>
+                <soap:body use="literal"/>
+            </wsdl:output>
+            <wsdl:fault name="pingMeFault">
+                <wsp:Policy xmlns:wsp="http://www.w3.org/2006/07/ws-policy">
+                    <http-conf:client xmlns:http-conf="http://cxf.apache.org/transports/http/configuration"
+                        DecoupledEndpoint="http://localhost:9997/decoupled_endpoint"/>
+                </wsp:Policy>
+                <soap:fault name="pingMeFault" use="literal"/>
+            </wsdl:fault>
+        </wsdl:operation>
+        
+    </wsdl:binding>
+   
+    <wsdl:service name="BasicGreeterService">
+        <wsp:Policy xmlns:wsp="http://www.w3.org/2006/07/ws-policy">
+            <http-conf:client xmlns:http-conf="http://cxf.apache.org/transports/http/configuration"
+                    DecoupledEndpoint="http://localhost:9999/decoupled_endpoint"
+                    ReceiveTimeout="40000"/>
+        </wsp:Policy>
+        <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">
+                    <wsp:Policy/>
+                </wsam:Addressing>
+            </wsp:Policy>
+            -->
+        </wsdl:port>
+    </wsdl:service>
+
+</wsdl:definitions>
+

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/http_client_greeter.wsdl
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm.xml?view=diff&rev=526120&r1=526119&r2=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm.xml (original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rm.xml Fri
Apr  6 04:21:45 2007
@@ -31,7 +31,7 @@
 
     <bean id="org.apache.cxf.ws.policy.PolicyEngine" class="org.apache.cxf.ws.policy.spring.InitializingPolicyEngine">
         <property name="bus" ref="cxf"/>
-        <property name="registerInterceptors" value="true"/>
+        <property name="enabled" value="true"/>
     </bean>
 
     <bean class="org.apache.cxf.ws.policy.attachment.external.ExternalAttachmentProvider">

Modified: incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rmwsdl.xml
URL: http://svn.apache.org/viewvc/incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rmwsdl.xml?view=diff&rev=526120&r1=526119&r2=526120
==============================================================================
--- incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rmwsdl.xml
(original)
+++ incubator/cxf/trunk/systests/src/test/java/org/apache/cxf/systest/ws/policy/rmwsdl.xml
Fri Apr  6 04:21:45 2007
@@ -31,7 +31,7 @@
 
     <bean id="org.apache.cxf.ws.policy.PolicyEngine" class="org.apache.cxf.ws.policy.spring.InitializingPolicyEngine">
         <property name="bus" ref="cxf"/>
-        <property name="registerInterceptors" value="true"/>
+        <property name="enabled" value="true"/>
     </bean>
 
 </beans>



Mime
View raw message