cxf-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From egl...@apache.org
Subject svn commit: r703122 - in /cxf/sandbox/dosgi: dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/ dsw/cxf-dsw/src/main/resources/META-INF/ dsw/cxf-dsw/src/main/resources/OSGI-INF/ dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/ dsw/cxf-dsw/src/main/resourc...
Date Thu, 09 Oct 2008 10:34:33 GMT
Author: eglynn
Date: Thu Oct  9 03:34:32 2008
New Revision: 703122

URL: http://svn.apache.org/viewvc?rev=703122&view=rev
Log:
Applying patch for CXF-1851 on behalf of David Bosschaert

Added:
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml   (with props)
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/remote-services.xml   (with props)
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs1.xml   (with props)
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs2.xml   (with props)
    cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/
    cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/
    cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/
    cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml   (with props)
    cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/
    cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml   (with props)
    cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/
    cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/
    cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/
    cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml   (with props)
    cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/
    cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml   (with props)
    cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/
    cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/
    cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/
    cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml   (with props)
    cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/
    cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml   (with props)
    cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/
    cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/
    cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/
    cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml   (with props)
    cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/
    cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml   (with props)
    cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/
    cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/
    cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/
    cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/intent-map.xml   (with props)
    cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/
    cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/remote-services.xml   (with props)
Removed:
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/META-INF/
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/META-INF/
    cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/META-INF/
    cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/META-INF/
    cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/META-INF/
    cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/META-INF/
    cxf/sandbox/dosgi/systests/basic/src/test/resources/META-INF/
Modified:
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/OsgiUtils.java
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/OsgiUtilsTest.java
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfListenerHookTest.java
    cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfPublishHookTest.java

Modified: cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/OsgiUtils.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/OsgiUtils.java?rev=703122&r1=703121&r2=703122&view=diff
==============================================================================
--- cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/OsgiUtils.java (original)
+++ cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/java/org/apache/cxf/dosgi/dsw/OsgiUtils.java Thu Oct  9 03:34:32 2008
@@ -51,12 +51,14 @@
 
     private static final Logger LOG = 
         Logger.getLogger(OsgiUtils.class.getName());    
-    private static final String REMOTE_SERVICES_ENTRY = 
-        "/META-INF/osgi/remote-services.xml";
+    
+    private static final String REMOTE_SERVICES_HEADER_NAME = "Remote-Service";
+    private static final String REMOTE_SERVICES_DIRECTORY =
+        "OSGI-INF/remote-services";
     private static final String REMOTE_SERVICES_NS =
         "http://www.osgi.org/xmlns/sd/v1.0.0";
     
-    static final String[] INTENT_MAP = {"/META-INF/osgi/intent-map.xml"};
+    static final String[] INTENT_MAP = {"/OSGI-INF/cxf/intents/intent-map.xml"};
     
     private static final String SERVICE_DESCRIPTION_ELEMENT = "service-description";
     
@@ -101,7 +103,7 @@
     public static List<ServiceEndpointDescription> getRemoteReferences(
         Bundle b, String[] names, Map<String, Object> userProperties, boolean matchAllNames) {
         
-        List<Element> references = getAllReferenceElements(b);
+        List<Element> references = getAllDescriptionElements(b);
         
         List<ServiceEndpointDescription> srefs = new ArrayList<ServiceEndpointDescription>();
         Namespace ns = Namespace.getNamespace(REMOTE_SERVICES_NS);
@@ -122,8 +124,7 @@
     
     @SuppressWarnings("unchecked")
     public static List<ServiceEndpointDescription> getAllRemoteReferences(Bundle b) {
-        
-        List<Element> references = getAllReferenceElements(b);
+        List<Element> references = getAllDescriptionElements(b);
         
         List<ServiceEndpointDescription> srefs = new ArrayList<ServiceEndpointDescription>();
         Namespace ns = Namespace.getNamespace(REMOTE_SERVICES_NS);
@@ -137,20 +138,35 @@
     }
     
     @SuppressWarnings("unchecked")
-    public static List<Element> getAllReferenceElements(Bundle b) {
-        URL resourceURL = b.getEntry(REMOTE_SERVICES_ENTRY);
-        if (resourceURL != null) {
+    public static List<Element> getAllDescriptionElements(Bundle b) {
+        Object directory = null;
+        
+        Dictionary headers = b.getHeaders();
+        if (headers != null) {
+            directory = headers.get(REMOTE_SERVICES_HEADER_NAME);
+        }
+        
+        if (directory == null) {
+            directory = REMOTE_SERVICES_DIRECTORY;
+        }
+        
+        Enumeration urls = b.findEntries(directory.toString(), "*.xml", false);
+        if (urls == null) {
+            return Collections.emptyList();
+        }
+
+        List<Element> elements = new ArrayList<Element>();
+        while (urls.hasMoreElements()) {
+            URL resourceURL = (URL) urls.nextElement();
             try {
                 Document d = new SAXBuilder().build(resourceURL.openStream());
                 Namespace ns = Namespace.getNamespace(REMOTE_SERVICES_NS);
-                
-                return d.getRootElement().getChildren(SERVICE_DESCRIPTION_ELEMENT, ns);
+                elements.addAll(d.getRootElement().getChildren(SERVICE_DESCRIPTION_ELEMENT, ns));
             } catch (Exception ex) {
-                System.out.println("Problem parsing remote-services.xml :" 
-                                   + ex.getMessage());
-            }
+                LOG.log(Level.WARNING, "Problem parsing: " + resourceURL, ex);
+            }            
         }
-        return Collections.emptyList(); 
+        return elements; 
     }
     
     private static boolean serviceNamesMatch(
@@ -199,11 +215,11 @@
                 props.put(key, sd.getProperty(key.toString()));
             }
         }
-        props.put(org.osgi.framework.Constants.OBJECTCLASS,
+        props.put(org.osgi.framework.Constants.OBJECTCLASS, 
                   getInterfaceNames(sd, interfaceName));
         return filter.match(props);
     }
-
+    
     public static String[] getInterfaceNames(ServiceEndpointDescription sd, String interfaceName) {
         
         String[] interfaceNames = sd.getInterfaceNames();

Added: cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml (added)
+++ cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,64 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:p="http://cxf.apache.org/policy"
+       xmlns:wsp="http://www.w3.org/ns/ws-policy"
+       xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
+       xmlns:core="http://cxf.apache.org/core"
+       xmlns:soap="http://cxf.apache.org/bindings/soap"
+       xsi:schemaLocation="
+       http://cxf.apache.org/policy http://cxf.apache.org/schemas/policy.xsd
+       http://www.w3.org/ns/ws-policy http://www.w3.org/2007/02/ws-policy.xsd
+       http://cxf.apache.org/core http://cxf.apache.org/schemas/core.xsd
+       http://cxf.apache.org/bindings/soap http://cxf.apache.org/schemas/configuration/soap.xsd
+       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+    <bean id="intentMap" class="org.apache.cxf.dosgi.dsw.qos.IntentMap">
+       <property name="intents">
+         <map>
+           <entry key="addressing" value-ref="nonDecoupledAddressing"/>
+           <entry key="logging" value-ref="messageLogging"/>
+           <entry key="SOAP" value-ref="soap11Binding"/>
+           <entry key="SOAP.1_1" value-ref="soap11Binding"/>
+           <entry key="SOAP.1_2" value-ref="soap12Binding"/>
+           <entry key="HTTP" value="PROVIDED"/>
+         </map>
+       </property>
+    </bean>
+
+    <p:policies id="nonDecoupledAddressing">
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <wsp:Policy wsu:Id="AddressingPolicy"
+        xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
+        <wsam:Addressing>
+            <wsp:Policy />
+        </wsam:Addressing>
+    </wsp:Policy>
+
+    <core:logging id="messageLogging"/>
+
+    <soap:soapBinding id="soap11Binding" version="1.1"/>
+    <soap:soapBinding id="soap12Binding" version="1.2"/>
+
+</beans>

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Modified: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/OsgiUtilsTest.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/OsgiUtilsTest.java?rev=703122&r1=703121&r2=703122&view=diff
==============================================================================
--- cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/OsgiUtilsTest.java (original)
+++ cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/OsgiUtilsTest.java Thu Oct  9 03:34:32 2008
@@ -1,13 +1,20 @@
 package org.apache.cxf.dosgi.dsw;
 
+import java.net.URL;
 import java.util.Arrays;
+import java.util.Collections;
+import java.util.Dictionary;
 import java.util.HashMap;
+import java.util.Hashtable;
+import java.util.List;
 import java.util.Map;
 
 import junit.framework.TestCase;
 
 import org.easymock.EasyMock;
 import org.easymock.IAnswer;
+import org.jdom.Element;
+import org.jdom.Namespace;
 import org.osgi.framework.Bundle;
 import org.osgi.framework.BundleContext;
 import org.osgi.framework.ServiceReference;
@@ -62,4 +69,70 @@
         
         assertEquals(initial, OsgiUtils.formatIntents(actual));
     }
+    
+    public void testNoRemoteServicesXMLFiles() {
+        Bundle b = EasyMock.createNiceMock(Bundle.class);
+        EasyMock.replay(b);
+        
+        List<Element> rsElements = OsgiUtils.getAllDescriptionElements(b);
+        assertEquals(0, rsElements.size());        
+    }
+    
+    public void testRemoteServicesXMLFiles() {
+        URL rs1URL = getClass().getResource("/test-resources/rs1.xml");
+        
+        Bundle b = EasyMock.createNiceMock(Bundle.class);
+        EasyMock.expect(b.findEntries(
+            EasyMock.eq("OSGI-INF/remote-services"), 
+            EasyMock.eq("*.xml"), EasyMock.anyBoolean())).andReturn(
+                Collections.enumeration(Arrays.asList(rs1URL))).anyTimes();
+        EasyMock.replay(b);
+        
+        List<Element> rsElements = OsgiUtils.getAllDescriptionElements(b);
+        assertEquals(2, rsElements.size());
+        Namespace ns = Namespace.getNamespace("http://www.osgi.org/xmlns/sd/v1.0.0");
+        assertEquals("SomeService", rsElements.get(0).getChild("interface", ns).getAttributeValue("name"));
+        assertEquals("SomeOtherService", rsElements.get(1).getChild("interface", ns).getAttributeValue("name"));
+    }
+    
+    public void testMultiRemoteServicesXMLFiles() {
+        URL rs1URL = getClass().getResource("/test-resources/rs1.xml");
+        URL rs2URL = getClass().getResource("/test-resources/rs2.xml");
+        
+        Bundle b = EasyMock.createNiceMock(Bundle.class);
+        EasyMock.expect(b.findEntries(
+            EasyMock.eq("OSGI-INF/remote-services"), 
+            EasyMock.eq("*.xml"), EasyMock.anyBoolean())).andReturn(
+                Collections.enumeration(Arrays.asList(rs1URL, rs2URL))).anyTimes();
+        EasyMock.replay(b);
+        
+        List<Element> rsElements = OsgiUtils.getAllDescriptionElements(b);
+        assertEquals(3, rsElements.size());
+        Namespace ns = Namespace.getNamespace("http://www.osgi.org/xmlns/sd/v1.0.0");
+        assertEquals("SomeService", rsElements.get(0).getChild("interface", ns).getAttributeValue("name"));
+        assertEquals("SomeOtherService", rsElements.get(1).getChild("interface", ns).getAttributeValue("name"));
+        assertEquals("org.example.Service", rsElements.get(2).getChild("interface", ns).getAttributeValue("name"));
+    }
+    
+    @SuppressWarnings("unchecked")
+    public void testRemoteServicesXMLFileAlternateLocation() {
+        URL rs1URL = getClass().getResource("/test-resources/rs1.xml");
+        Dictionary headers = new Hashtable();        
+        headers.put("Remote-Service", "META-INF/osgi");
+        headers.put("Bundle-Name", "testing bundle");
+        
+        Bundle b = EasyMock.createNiceMock(Bundle.class);
+        EasyMock.expect(b.getHeaders()).andReturn(headers).anyTimes();
+        EasyMock.expect(b.findEntries(
+            EasyMock.eq("META-INF/osgi"), 
+            EasyMock.eq("*.xml"), EasyMock.anyBoolean())).andReturn(
+                Collections.enumeration(Arrays.asList(rs1URL))).anyTimes();
+        EasyMock.replay(b);
+        
+        List<Element> rsElements = OsgiUtils.getAllDescriptionElements(b);
+        assertEquals(2, rsElements.size());
+        Namespace ns = Namespace.getNamespace("http://www.osgi.org/xmlns/sd/v1.0.0");
+        assertEquals("SomeService", rsElements.get(0).getChild("interface", ns).getAttributeValue("name"));
+        assertEquals("SomeOtherService", rsElements.get(1).getChild("interface", ns).getAttributeValue("name"));
+    }
 }

Modified: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfListenerHookTest.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfListenerHookTest.java?rev=703122&r1=703121&r2=703122&view=diff
==============================================================================
--- cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfListenerHookTest.java (original)
+++ cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfListenerHookTest.java Thu Oct  9 03:34:32 2008
@@ -18,6 +18,8 @@
   */
 package org.apache.cxf.dosgi.dsw.hooks;
 
+import java.util.Arrays;
+import java.util.Collections;
 import java.util.Dictionary;
 import java.util.Hashtable;
 import java.util.List;
@@ -45,9 +47,10 @@
     public void testSyncListenerHook() throws Exception {
         
         Bundle bundle = control.createMock(Bundle.class);
-        bundle.getEntry("/META-INF/osgi/remote-services.xml");
-        EasyMock.expectLastCall().andReturn(
-            getClass().getResource("/META-INF/osgi/remote-services.xml"));
+        bundle.findEntries(EasyMock.eq("OSGI-INF/remote-services"), 
+            EasyMock.eq("*.xml"), EasyMock.anyBoolean());
+        EasyMock.expectLastCall().andReturn(Collections.enumeration(
+            Arrays.asList(getClass().getResource("/OSGI-INF/remote-services/remote-services.xml"))));
         Dictionary<String, String> bundleHeaders = new Hashtable<String, String>();
         bundleHeaders.put(org.osgi.framework.Constants.BUNDLE_NAME, 
                           "Test Bundle");

Modified: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfPublishHookTest.java
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfPublishHookTest.java?rev=703122&r1=703121&r2=703122&view=diff
==============================================================================
--- cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfPublishHookTest.java (original)
+++ cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/java/org/apache/cxf/dosgi/dsw/hooks/CxfPublishHookTest.java Thu Oct  9 03:34:32 2008
@@ -18,6 +18,8 @@
   */
 package org.apache.cxf.dosgi.dsw.hooks;
 
+import java.util.Arrays;
+import java.util.Collections;
 import java.util.Dictionary;
 import java.util.Hashtable;
 import java.util.Map;
@@ -51,9 +53,10 @@
     public void testPublishHook() throws Exception {
         
         Bundle bundle = control.createMock(Bundle.class);
-        bundle.getEntry("/META-INF/osgi/remote-services.xml");
-        EasyMock.expectLastCall().andReturn(
-            getClass().getResource("/META-INF/osgi/remote-services.xml"));
+        bundle.findEntries(EasyMock.eq("OSGI-INF/remote-services"), 
+            EasyMock.eq("*.xml"), EasyMock.anyBoolean());
+        EasyMock.expectLastCall().andReturn(Collections.enumeration(
+            Arrays.asList(getClass().getResource("/OSGI-INF/remote-services/remote-services.xml"))));
         Dictionary<String, String> bundleHeaders = new Hashtable<String, String>();
         bundleHeaders.put(org.osgi.framework.Constants.BUNDLE_NAME, 
                           "Test Bundle");

Added: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/remote-services.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/remote-services.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/remote-services.xml (added)
+++ cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/remote-services.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,30 @@
+<?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.
+-->
+
+<service-descriptions xmlns="http://www.osgi.org/xmlns/sd/v1.0.0">
+  <service-description>
+    <interface name="org.apache.cxf.dosgi.dsw.hooks.TestService" />
+    <property key="osgi.remote.interfaces">true</property>
+    <property key="osgi.remote.requires.intents">SOAP HTTP</property>
+    <property key="osgi.remote.configuration.type">pojo</property>
+    <property key="osgi.remote.configuration.pojo.address">http://localhost:9000/hello</property>
+  </service-description>
+</service-descriptions>

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs1.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs1.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs1.xml (added)
+++ cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs1.xml Thu Oct  9 03:34:32 2008
@@ -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.
+-->
+
+<service-descriptions xmlns="http://www.osgi.org/xmlns/sd/v1.0.0">
+  <service-description>
+    <interface name="SomeService" />
+    <property key="osgi.remote.requires.intents">confidentiality</property>
+  </service-description>
+  <service-description>
+    <interface name="SomeOtherService" />
+    <interface name="WithSomeSecondInterface" />
+  </service-description>
+</service-descriptions>

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs1.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs1.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs1.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs2.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs2.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs2.xml (added)
+++ cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs2.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,28 @@
+<?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.
+-->
+
+<service-descriptions xmlns="http://www.osgi.org/xmlns/sd/v1.0.0">
+  <service-description>
+    <interface name="org.example.Service" />
+    <property key="osgi.intents">confidentiality.message integrity</property>
+    <property key="osgi.remote.interfaces">*</property>
+  </service-description>
+</service-descriptions>

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs2.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs2.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/dsw/cxf-dsw/src/test/resources/test-resources/rs2.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml (added)
+++ cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:p="http://cxf.apache.org/policy"
+       xmlns:wsp="http://www.w3.org/ns/ws-policy"
+       xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
+       xmlns:http="http://cxf.apache.org/transports/http/configuration"
+       xmlns:wsrm-policy="http://schemas.xmlsoap.org/ws/2005/02/rm/policy"
+       xsi:schemaLocation="
+       http://cxf.apache.org/policy http://cxf.apache.org/schemas/policy.xsd
+       http://www.w3.org/ns/ws-policy http://www.w3.org/2007/02/ws-policy.xsd
+       http://cxf.apache.org/transports/http/configuration http://cxf.apache.org/schemas/configuration/http-conf.xsd
+       http://schemas.xmlsoap.org/ws/2005/02/rm/policy http://schemas.xmlsoap.org/ws/2005/02/rm/wsrm-policy.xsd
+       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+    <bean id="intentMap" class="org.apache.cxf.dosgi.dsw.qos.IntentMap">
+       <property name="intents">
+         <map>
+           <entry key="reliability" value-ref="reliableMessaging"/>
+           <entry key="decoupled" value-ref="decoupledAddressing"/>
+         </map>
+       </property>
+    </bean>
+
+    <p:policies id="reliableMessaging">
+        <wsp:PolicyReference URI="#ReliabilityPolicy"/>
+        <wsp:PolicyReference URI="#DecoupledPolicy"/>
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <p:policies id="decoupledAddressing">
+        <wsp:PolicyReference URI="#DecoupledPolicy"/>
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <wsp:Policy wsu:Id="ReliabilityPolicy">
+        <wsrm-policy:RMAssertion>
+            <wsrm-policy:BaseRetransmissionInterval Milliseconds="4000"/>
+            <wsrm-policy:AcknowledgementInterval Milliseconds="2000" />
+        </wsrm-policy:RMAssertion>
+    </wsp:Policy>
+
+    <wsp:Policy wsu:Id="DecoupledPolicy">
+        <wsp:ExactlyOne>
+            <http:client DecoupledEndpoint="http://localhost:9970/decoupled_endpoint"/>
+        </wsp:ExactlyOne>
+    </wsp:Policy>
+
+    <wsp:Policy wsu:Id="AddressingPolicy"
+        xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
+        <wsam:Addressing>
+            <wsp:Policy />
+        </wsam:Addressing>
+    </wsp:Policy>
+
+</beans>

Propchange: cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml (added)
+++ cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,28 @@
+<?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.
+  -->
+<service-descriptions xmlns="http://www.osgi.org/xmlns/sd/v1.0.0">
+  <service-description>
+    <interface name="org.apache.cxf.dosgi.samples.greeter.GreeterService" />
+    <property key="osgi.remote.interfaces">true</property>
+    <property key="osgi.remote.requires.intents">SOAP HTTP</property>
+    <!--
+      property name="osgi.remote.requires.intents">reliability decoupled
+      SOAP HTTP</property
+    -->
+    <property key="osgi.remote.configuration.type">pojo</property>
+    <property key="osgi.remote.configuration.pojo.address">http://localhost:9090/greeter</property>
+  </service-description>
+</service-descriptions>

Propchange: cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/samples/greeter/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml (added)
+++ cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,60 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:p="http://cxf.apache.org/policy"
+       xmlns:wsp="http://www.w3.org/ns/ws-policy"
+       xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
+       xmlns:wsrm-policy="http://schemas.xmlsoap.org/ws/2005/02/rm/policy"
+       xsi:schemaLocation="
+       http://cxf.apache.org/policy http://cxf.apache.org/schemas/policy.xsd
+       http://www.w3.org/ns/ws-policy http://www.w3.org/2007/02/ws-policy.xsd
+       http://schemas.xmlsoap.org/ws/2005/02/rm/policy http://schemas.xmlsoap.org/ws/2005/02/rm/wsrm-policy.xsd
+       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+    <bean id="intentMap" class="org.apache.cxf.dosgi.dsw.qos.IntentMap">
+       <property name="intents">
+         <map>
+           <entry key="reliability" value-ref="reliableMessaging"/>
+         </map>
+       </property>
+    </bean>
+
+    <p:policies id="reliableMessaging">
+        <wsp:PolicyReference URI="#ReliabilityPolicy"/>
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <wsp:Policy wsu:Id="ReliabilityPolicy">
+        <wsrm-policy:RMAssertion>
+            <wsrm-policy:BaseRetransmissionInterval Milliseconds="99999999"/>
+            <wsrm-policy:AcknowledgementInterval Milliseconds="2000" />
+        </wsrm-policy:RMAssertion>
+    </wsp:Policy>
+
+    <wsp:Policy wsu:Id="AddressingPolicy"
+        xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
+        <wsam:Addressing>
+            <wsp:Policy />
+        </wsam:Addressing>
+    </wsp:Policy>
+
+</beans>

Propchange: cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml (added)
+++ cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,24 @@
+<?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.
+  -->
+<service-descriptions xmlns="http://www.osgi.org/xmlns/sd/v1.0.0">
+  <service-description>
+    <interface name="org.apache.cxf.dosgi.samples.greeter.GreeterService" />
+    <property key="osgi.remote.interfaces">true</property>
+    <property key="osgi.remote.requires.intents">SOAP HTTP</property>
+    <property key="osgi.remote.configuration.type">pojo</property>
+    <property key="osgi.remote.configuration.pojo.address">http://localhost:9090/greeter</property>
+  </service-description>
+</service-descriptions>

Propchange: cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/samples/greeter/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml (added)
+++ cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,76 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+
+
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:p="http://cxf.apache.org/policy"
+       xmlns:wsp="http://www.w3.org/ns/ws-policy"
+       xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
+       xmlns:http="http://cxf.apache.org/transports/http/configuration"
+       xmlns:wsrm-policy="http://schemas.xmlsoap.org/ws/2005/02/rm/policy"
+       xsi:schemaLocation="
+       http://cxf.apache.org/policy http://cxf.apache.org/schemas/policy.xsd
+       http://www.w3.org/ns/ws-policy http://www.w3.org/2007/02/ws-policy.xsd
+       http://cxf.apache.org/transports/http/configuration http://cxf.apache.org/schemas/configuration/http-conf.xsd
+       http://schemas.xmlsoap.org/ws/2005/02/rm/policy http://schemas.xmlsoap.org/ws/2005/02/rm/wsrm-policy.xsd
+       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+    <bean id="intentMap" class="org.apache.cxf.dosgi.dsw.qos.IntentMap">
+       <property name="intents">
+         <map>
+           <entry key="reliability" value-ref="reliableMessaging"/>
+           <entry key="decoupled" value-ref="decoupledAddressing"/>
+         </map>
+       </property>
+    </bean>
+
+    <p:policies id="reliableMessaging">
+        <wsp:PolicyReference URI="#ReliabilityPolicy"/>
+        <wsp:PolicyReference URI="#DecoupledPolicy"/>
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <p:policies id="decoupledAddressing">
+        <wsp:PolicyReference URI="#DecoupledPolicy"/>
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <wsp:Policy wsu:Id="ReliabilityPolicy">
+        <wsrm-policy:RMAssertion>
+            <wsrm-policy:BaseRetransmissionInterval Milliseconds="4000"/>
+            <wsrm-policy:AcknowledgementInterval Milliseconds="2000" />
+        </wsrm-policy:RMAssertion>
+    </wsp:Policy>
+
+    <wsp:Policy wsu:Id="DecoupledPolicy">
+        <wsp:ExactlyOne>
+            <http:client DecoupledEndpoint="http://localhost:9970/decoupled_endpoint"/>
+        </wsp:ExactlyOne>
+    </wsp:Policy>
+
+    <wsp:Policy wsu:Id="AddressingPolicy"
+        xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
+        <wsam:Addressing>
+            <wsp:Policy />
+        </wsam:Addressing>
+    </wsp:Policy>
+
+</beans>

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml (added)
+++ cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,36 @@
+<?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.
+  -->
+<service-descriptions xmlns="http://www.osgi.org/xmlns/sd/v1.0.0">
+  <service-description>
+    <interface name="org.apache.cxf.dosgi.samples.pojo.hello.HelloService" />
+    <property key="osgi.remote.interfaces">true</property>
+
+<!-- Uncomment to enable SOAP 1.2 and confirm via message logging -->
+    <!--
+      property name="osgi.remote.requires.intents">logging SOAP.1_2
+      HTTP</property
+    -->
+
+<!-- Uncomment to enable WS-RM and confirm via message logging -->
+    <!--
+      property name="osgi.remote.requires.intents">logging reliability
+      SOAP HTTP</property
+    -->
+    <property key="osgi.remote.requires.intents">SOAP HTTP</property>
+    <property key="osgi.remote.configuration.type">pojo</property>
+    <property key="osgi.remote.configuration.pojo.address">http://localhost:9000/hello</property>
+  </service-description>
+</service-descriptions>

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/client/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml (added)
+++ cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,61 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+
+
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:p="http://cxf.apache.org/policy"
+       xmlns:wsp="http://www.w3.org/ns/ws-policy"
+       xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
+       xmlns:wsrm-policy="http://schemas.xmlsoap.org/ws/2005/02/rm/policy"
+       xsi:schemaLocation="
+       http://cxf.apache.org/policy http://cxf.apache.org/schemas/policy.xsd
+       http://www.w3.org/ns/ws-policy http://www.w3.org/2007/02/ws-policy.xsd
+       http://schemas.xmlsoap.org/ws/2005/02/rm/policy http://schemas.xmlsoap.org/ws/2005/02/rm/wsrm-policy.xsd
+       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+    <bean id="intentMap" class="org.apache.cxf.dosgi.dsw.qos.IntentMap">
+       <property name="intents">
+         <map>
+           <entry key="reliability" value-ref="reliableMessaging"/>
+         </map>
+       </property>
+    </bean>
+
+    <p:policies id="reliableMessaging">
+        <wsp:PolicyReference URI="#ReliabilityPolicy"/>
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <wsp:Policy wsu:Id="ReliabilityPolicy">
+        <wsrm-policy:RMAssertion>
+            <wsrm-policy:BaseRetransmissionInterval Milliseconds="99999999"/>
+            <wsrm-policy:AcknowledgementInterval Milliseconds="2000" />
+        </wsrm-policy:RMAssertion>
+    </wsp:Policy>
+
+    <wsp:Policy wsu:Id="AddressingPolicy"
+        xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
+        <wsam:Addressing>
+            <wsp:Policy />
+        </wsam:Addressing>
+    </wsp:Policy>
+
+</beans>

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml (added)
+++ cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,43 @@
+<?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.
+  -->
+<service-descriptions xmlns="http://www.osgi.org/xmlns/sd/v1.0.0">
+  <service-description>
+    <interface name="org.apache.cxf.dosgi.samples.pojo.hello.HelloService" />
+    <property key="osgi.remote.interfaces">true</property>
+
+<!-- Uncomment to enable SOAP 1.2 and confirm via message logging -->
+    <!--
+      property name="osgi.remote.requires.intents">logging SOAP.1_2
+      HTTP</property
+    -->
+
+<!-- Uncomment to enable WS-RM and confirm via message logging -->
+    <!--
+      property name="osgi.remote.requires.intents">logging reliability
+      SOAP HTTP</property
+    -->
+    <property key="osgi.remote.requires.intents">SOAP HTTP</property>
+    <property key="osgi.remote.configuration.type">pojo</property>
+    <property key="osgi.remote.configuration.pojo.address">http://localhost:9000/hello</property>
+  </service-description>
+  <service-description>
+    <interface name="org.apache.cxf.dosgi.samples.pojo.hello.GreeterService" />
+    <property key="osgi.remote.interfaces">true</property>
+    <property key="osgi.remote.requires.intents">SOAP HTTP</property>
+    <property key="osgi.remote.configuration.type">pojo</property>
+    <property key="osgi.remote.configuration.pojo.address">http://localhost:9005/greeter</property>
+  </service-description>
+</service-descriptions>

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/samples/simple_pojo/impl/src/main/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/intent-map.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/intent-map.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/intent-map.xml (added)
+++ cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/intent-map.xml Thu Oct  9 03:34:32 2008
@@ -0,0 +1,75 @@
+<?xml version="1.0" encoding="UTF-8"?>
+<!--
+  Licensed to the Apache Software Foundation (ASF) under one
+  or more contributor license agreements. See the NOTICE file
+  distributed with this work for additional information
+  regarding copyright ownership. The ASF licenses this file
+  to you under the Apache License, Version 2.0 (the
+  "License"); you may not use this file except in compliance
+  with the License. You may obtain a copy of the License at
+
+  http://www.apache.org/licenses/LICENSE-2.0
+
+  Unless required by applicable law or agreed to in writing,
+  software distributed under the License is distributed on an
+  "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
+  KIND, either express or implied. See the License for the
+  specific language governing permissions and limitations
+  under the License.
+-->
+
+<beans xmlns="http://www.springframework.org/schema/beans"
+       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+       xmlns:p="http://cxf.apache.org/policy"
+       xmlns:wsp="http://www.w3.org/ns/ws-policy"
+       xmlns:wsu="http://docs.oasis-open.org/wss/2004/01/oasis-200401-wss-wssecurity-utility-1.0.xsd"
+       xmlns:http="http://cxf.apache.org/transports/http/configuration"
+       xmlns:wsrm-policy="http://schemas.xmlsoap.org/ws/2005/02/rm/policy"
+       xsi:schemaLocation="
+       http://cxf.apache.org/policy http://cxf.apache.org/schemas/policy.xsd
+       http://www.w3.org/ns/ws-policy http://www.w3.org/2007/02/ws-policy.xsd
+       http://cxf.apache.org/transports/http/configuration http://cxf.apache.org/schemas/configuration/http-conf.xsd
+       http://schemas.xmlsoap.org/ws/2005/02/rm/policy http://schemas.xmlsoap.org/ws/2005/02/rm/wsrm-policy.xsd
+       http://www.springframework.org/schema/beans http://www.springframework.org/schema/beans/spring-beans.xsd">
+
+    <bean id="intentMap" class="org.apache.cxf.dosgi.dsw.qos.IntentMap">
+       <property name="intents">
+         <map>
+           <entry key="reliability" value-ref="reliableMessaging"/>
+           <entry key="decoupled" value-ref="decoupledAddressing"/>
+         </map>
+       </property>
+    </bean>
+
+    <p:policies id="reliableMessaging">
+        <wsp:PolicyReference URI="#ReliabilityPolicy"/>
+        <wsp:PolicyReference URI="#DecoupledPolicy"/>
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <p:policies id="decoupledAddressing">
+        <wsp:PolicyReference URI="#DecoupledPolicy"/>
+        <wsp:PolicyReference URI="#AddressingPolicy"/>
+    </p:policies>
+
+    <wsp:Policy wsu:Id="ReliabilityPolicy">
+        <wsrm-policy:RMAssertion>
+            <wsrm-policy:BaseRetransmissionInterval Milliseconds="4000"/>
+            <wsrm-policy:AcknowledgementInterval Milliseconds="2000" />
+        </wsrm-policy:RMAssertion>
+    </wsp:Policy>
+
+    <wsp:Policy wsu:Id="DecoupledPolicy">
+        <wsp:ExactlyOne>
+            <http:client DecoupledEndpoint="http://localhost:9970/decoupled_endpoint"/>
+        </wsp:ExactlyOne>
+    </wsp:Policy>
+
+    <wsp:Policy wsu:Id="AddressingPolicy"
+        xmlns:wsam="http://www.w3.org/2007/02/addressing/metadata">
+        <wsam:Addressing>
+            <wsp:Policy />
+        </wsam:Addressing>
+    </wsp:Policy>
+
+</beans>

Propchange: cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/cxf/intents/intent-map.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml

Added: cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/remote-services.xml
URL: http://svn.apache.org/viewvc/cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/remote-services.xml?rev=703122&view=auto
==============================================================================
--- cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/remote-services.xml (added)
+++ cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/remote-services.xml Thu Oct  9 03:34:32 2008
@@ -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.
+  -->
+<service-descriptions xmlns="http://www.osgi.org/xmlns/sd/v1.0.0">
+  <service-description>
+    <interface name="org.apache.cxf.dosgi.samples.pojo.hello.HelloService" />
+    <property key="osgi.remote.interfaces">true</property>
+    <property key="osgi.remote.requires.intents">SOAP HTTP</property>
+    <property key="osgi.remote.configuration.type">pojo</property>
+    <property key="osgi.remote.configuration.pojo.address">http://localhost:9000/hello</property>
+  </service-description>
+  <service-description>
+    <interface name="org.apache.cxf.dosgi.samples.pojo.hello.GreeterService" />
+    <property key="osgi.remote.interfaces">true</property>
+    <property key="osgi.remote.requires.intents">SOAP HTTP</property>
+    <property key="osgi.remote.configuration.type">pojo</property>
+    <property key="osgi.remote.configuration.pojo.address">http://localhost:9005/greeter</property>
+  </service-description>
+</service-descriptions>

Propchange: cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:eol-style = native

Propchange: cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:keywords = Rev Date

Propchange: cxf/sandbox/dosgi/systests/basic/src/test/resources/OSGI-INF/remote-services/remote-services.xml
------------------------------------------------------------------------------
    svn:mime-type = text/xml



Mime
View raw message