You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@cxf.apache.org by cs...@apache.org on 2016/07/06 10:00:06 UTC

[1/3] cxf-dosgi git commit: Rename systests2 to itests to make it more similar to other projects

Repository: cxf-dosgi
Updated Branches:
  refs/heads/master 1fef30511 -> 7f75cc067


http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
deleted file mode 100644
index 383d7e9..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
+++ /dev/null
@@ -1,248 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi;
-
-import static org.ops4j.pax.exam.CoreOptions.composite;
-import static org.ops4j.pax.exam.CoreOptions.frameworkStartLevel;
-import static org.ops4j.pax.exam.CoreOptions.mavenBundle;
-import static org.ops4j.pax.exam.CoreOptions.systemProperty;
-import static org.ops4j.pax.exam.cm.ConfigurationAdminOptions.newConfiguration;
-
-import java.io.File;
-import java.io.IOException;
-import java.net.ConnectException;
-import java.net.HttpURLConnection;
-import java.net.InetSocketAddress;
-import java.net.MalformedURLException;
-import java.net.ServerSocket;
-import java.net.Socket;
-import java.net.URL;
-import java.util.Collection;
-import java.util.concurrent.TimeoutException;
-
-import javax.inject.Inject;
-
-import org.apache.zookeeper.ZooKeeper;
-import org.apache.zookeeper.data.Stat;
-import org.junit.Assert;
-import org.junit.BeforeClass;
-import org.ops4j.pax.exam.CoreOptions;
-import org.ops4j.pax.exam.Option;
-import org.ops4j.pax.exam.cm.ConfigurationAdminOptions;
-import org.ops4j.pax.exam.options.MavenArtifactProvisionOption;
-import org.ops4j.pax.exam.options.extra.VMOption;
-import org.osgi.framework.Bundle;
-import org.osgi.framework.BundleContext;
-import org.osgi.framework.BundleException;
-import org.osgi.framework.ServiceReference;
-
-public class AbstractDosgiTest {
-    static final int ZK_PORT = 35101;
-    private static final int TIMEOUT = 20;
-    
-    @Inject
-    BundleContext bundleContext;
-    
-    @BeforeClass
-    public static void log() {
-        System.out.println("-----------------------------------------------------------------");
-    }
-    
-
-    /**
-     * Sleeps for a short interval, throwing an exception if timeout has been reached. Used to facilitate a
-     * retry interval with timeout when used in a loop.
-     *
-     * @param startTime the start time of the entire operation in milliseconds
-     * @param timeout the timeout duration for the entire operation in seconds
-     * @param message the error message to use when timeout occurs
-     * @throws InterruptedException if interrupted while sleeping
-     */
-    private static void sleepOrTimeout(long startTime, long timeout, String message)
-        throws InterruptedException, TimeoutException {
-        timeout *= 1000; // seconds to millis
-        long elapsed = System.currentTimeMillis() - startTime;
-        long remaining = timeout - elapsed;
-        if (remaining <= 0) {
-            throw new TimeoutException(message);
-        }
-        long interval = Math.min(remaining, 1000);
-        Thread.sleep(interval);
-    }
-
-    @SuppressWarnings({
-                       "rawtypes", "unchecked"
-    })
-    protected ServiceReference waitService(BundleContext bc, Class cls, String filter, int timeout)
-        throws Exception {
-        System.out.println("Waiting for service: " + cls + " " + filter);
-        long startTime = System.currentTimeMillis();
-        while (true) {
-            Collection refs = bc.getServiceReferences(cls, filter);
-            if (refs != null && refs.size() > 0) {
-                return (ServiceReference)refs.iterator().next();
-            }
-            sleepOrTimeout(startTime, timeout, "Service not found: " + cls + " " + filter);
-        }
-    }
-
-    protected void waitPort(int port) throws Exception {
-        System.out.println("Waiting for server to appear on port: " + port);
-        long startTime = System.currentTimeMillis();
-        while (true) {
-            Socket s = null;
-            try {
-                s = new Socket((String)null, port);
-                // yep, its available
-                return;
-            } catch (IOException e) {
-                sleepOrTimeout(startTime, TIMEOUT, "Timeout waiting for port " + port);
-            } finally {
-                if (s != null) {
-                    try {
-                        s.close();
-                    } catch (IOException e) {
-                        // ignore
-                    }
-                }
-            }
-        }
-    }
-
-    protected Bundle getBundleByName(BundleContext bc, String name) {
-        for (Bundle bundle : bc.getBundles()) {
-            if (bundle.getSymbolicName().equals(name)) {
-                return bundle;
-            }
-        }
-        return null;
-    }
-
-    protected static int getFreePort() {
-        try (ServerSocket socket = new ServerSocket()) {
-            socket.setReuseAddress(true); // enables quickly reopening socket on same port
-            socket.bind(new InetSocketAddress(0)); // zero finds a free port
-            return socket.getLocalPort();
-        } catch (Exception e) {
-            throw new RuntimeException(e.getMessage(), e);
-        }
-    }
-
-    protected void waitWebPage(String urlSt) throws InterruptedException, TimeoutException {
-        System.out.println("Waiting for url " + urlSt);
-        HttpURLConnection con = null;
-        long startTime = System.currentTimeMillis();
-        while (true) {
-            try {
-                URL url = new URL(urlSt);
-                con = (HttpURLConnection)url.openConnection();
-                int status = con.getResponseCode();
-                if (status == 200) {
-                    return;
-                }
-            } catch (ConnectException e) {
-                // Ignore connection refused
-            } catch (MalformedURLException e) {
-                throw new RuntimeException(e.getMessage(), e);
-            } catch (IOException e) {
-                throw new RuntimeException(e.getMessage(), e);
-            } finally {
-                if (con != null) {
-                    con.disconnect();
-                }
-            }
-            sleepOrTimeout(startTime, TIMEOUT, "Timeout waiting for web page " + urlSt);
-        }
-    }
-
-    protected void assertBundlesStarted() {
-        for (Bundle bundle : bundleContext.getBundles()) {
-            System.out
-                .println(bundle.getSymbolicName() + ":" + bundle.getVersion() + ": " + bundle.getState());
-            if (bundle.getState() != Bundle.ACTIVE) {
-                try {
-                    bundle.start();
-                } catch (BundleException e) {
-                    e.printStackTrace();
-                }
-            }
-        }
-    }
-
-    protected ZooKeeper createZookeeperClient() throws IOException {
-        return new ZooKeeper("localhost:" + ZK_PORT, 1000, null);
-    }
-
-    protected void assertNodeExists(ZooKeeper zk, String zNode, int timeout) {
-        long endTime = System.currentTimeMillis() + timeout;
-        Stat stat = null;
-        while (stat == null && System.currentTimeMillis() < endTime) {
-            try {
-                stat = zk.exists(zNode, null);
-                Thread.sleep(200);
-            } catch (Exception e) {
-                // Ignore
-            }
-        }
-        Assert.assertNotNull("ZooKeeper node " + zNode + " was not found", stat);
-    }
-
-    protected static Option configZKConsumer() {
-        return newConfiguration("org.apache.aries.rsa.discovery.zookeeper") //
-            .put("zookeeper.host", "127.0.0.1") //
-            .put("zookeeper.port", "" + ZK_PORT).asOption();
-    }
-
-    protected static Option configZKServer() {
-        return newConfiguration("org.apache.aries.rsa.discovery.zookeeper.server")
-            .put("clientPort", "" + ZK_PORT) //
-            .asOption();
-    }
-    
-    protected static Option configLogging() {
-        return ConfigurationAdminOptions.configurationFolder(new File("src/test/resources/cfg"));
-    }
-    
-
-    protected static MavenArtifactProvisionOption greeterImpl() {
-        return mavenBundle().groupId("org.apache.cxf.dosgi.samples")
-            .artifactId("cxf-dosgi-ri-samples-greeter-impl").versionAsInProject();
-    }
-
-    protected static MavenArtifactProvisionOption greeterInterface() {
-        return mavenBundle().groupId("org.apache.cxf.dosgi.samples")
-            .artifactId("cxf-dosgi-ri-samples-greeter-interface").versionAsInProject();
-    }
-
-    protected static Option basicTestOptions() throws Exception {
-        return composite(MultiBundleTools.getDistro(), //
-                         CoreOptions.junitBundles(), //
-                         systemProperty("org.ops4j.pax.logging.DefaultServiceLog.level").value("INFO"), //
-                         systemProperty("pax.exam.osgi.unresolved.fail").value("true"), //
-                         configLogging(),
-                         frameworkStartLevel(100)
-        );
-    }
-
-
-    protected static VMOption debug() {
-        return CoreOptions.vmOption("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005");
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/GreeterServiceProxyFactory.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/GreeterServiceProxyFactory.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/GreeterServiceProxyFactory.java
deleted file mode 100644
index 074a6f1..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/GreeterServiceProxyFactory.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi;
-
-import org.apache.cxf.aegis.databinding.AegisDatabinding;
-import org.apache.cxf.dosgi.samples.greeter.GreeterService;
-import org.apache.cxf.frontend.ClientProxyFactoryBean;
-
-public final class GreeterServiceProxyFactory {
-
-    private GreeterServiceProxyFactory() {
-    }
-
-    protected static GreeterService createGreeterServiceProxy(String serviceUri) {
-        ClassLoader cl = Thread.currentThread().getContextClassLoader();
-        Thread.currentThread().setContextClassLoader(ClientProxyFactoryBean.class.getClassLoader());
-        try {
-            ClientProxyFactoryBean factory = new ClientProxyFactoryBean();
-            factory.setServiceClass(GreeterService.class);
-            factory.setAddress(serviceUri);
-            factory.getServiceFactory().setDataBinding(new AegisDatabinding());
-            return (GreeterService)factory.create();
-        } finally {
-            Thread.currentThread().setContextClassLoader(cl);
-        }
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/MultiBundleTools.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/MultiBundleTools.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/MultiBundleTools.java
deleted file mode 100644
index 70e4816..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/MultiBundleTools.java
+++ /dev/null
@@ -1,102 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi;
-
-import java.io.File;
-import java.io.FileInputStream;
-import java.io.FileNotFoundException;
-import java.io.IOException;
-import java.net.URL;
-import java.util.ArrayList;
-import java.util.List;
-import java.util.Map;
-import java.util.Properties;
-import java.util.TreeMap;
-
-import org.ops4j.pax.exam.CoreOptions;
-import org.ops4j.pax.exam.Option;
-
-public final class MultiBundleTools {
-
-    private MultiBundleTools() {
-    }
-    
-    private static Properties getProps(File distroDir) throws FileNotFoundException, IOException {
-        Properties p = new Properties();
-        File confFile = new File(distroDir, "conf/felix.config.properties.append");
-        p.load(new FileInputStream(confFile));
-        return p;
-    }
-
-    private static int getDistroBundles(File distroDir,
-                                        Properties props, 
-                                        Map<Integer, String> bundles) throws Exception {
-        int startLevel = Integer.parseInt(props.getProperty("org.osgi.framework.startlevel.beginning"));
-        for (int i = 0; i <= startLevel; i++) {
-            String val = props.getProperty("felix.auto.start." + i);
-            if (val != null) {
-                if (val.startsWith("file:")) {
-                    File fullDir = new File(distroDir, val.substring("file:".length()));
-                    bundles.put(i, fullDir.toURI().toASCIIString());
-                } else {
-                    if (!val.contains("org.osgi.compendium")) {
-                        // We're skipping that one as it's pulled in explicitly in the test
-                        bundles.put(i, val);
-                    }
-                }
-            }
-        }
-        return startLevel + 1; // Add 1 to start level to be on the safe side
-    }
-
-    private static File getRootDirectory() {
-        String resourceName = "/" + MultiBundleTools.class.getName().replace('.', '/') + ".class";
-        URL curURL = MultiBundleTools.class.getResource(resourceName);
-        File curFile = new File(curURL.getFile());
-        String curString = curFile.getAbsolutePath();
-        File curBase = new File(curString.substring(0, curString.length() - resourceName.length()));
-        return curBase.getParentFile().getParentFile();
-    }
-
-    private static Option[] getDistroBundleOptions() throws Exception {
-        Map<Integer, String> bundles = new TreeMap<Integer, String>();
-        File root = getRootDirectory();
-        File depRoot = new File(root, "target/dependency");
-        File distroDir = depRoot.listFiles()[0];
-        Properties props = getProps(distroDir);
-        getDistroBundles(distroDir, props, bundles);
-        List<Option> opts = new ArrayList<Option>();
-        
-        /*
-        String sysPackagesValue = props.getProperty("org.osgi.framework.system.packages");
-        opts.add(CoreOptions.frameworkProperty("org.osgi.framework.system.packages")
-                 .value(sysPackagesValue));
-        */
-
-        for (Map.Entry<Integer, String> entry : bundles.entrySet()) {
-            String bundleUri = entry.getValue();
-            opts.add(CoreOptions.bundle(bundleUri));
-        }
-        return opts.toArray(new Option[opts.size()]);
-    }
-
-    public static Option getDistro() throws Exception {
-        return CoreOptions.composite(getDistroBundleOptions());
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestCustomIntent.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestCustomIntent.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestCustomIntent.java
deleted file mode 100644
index 9928db0..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestCustomIntent.java
+++ /dev/null
@@ -1,91 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi;
-
-import static org.apache.cxf.dosgi.systests2.multi.GreeterServiceProxyFactory.createGreeterServiceProxy;
-import static org.ops4j.pax.exam.CoreOptions.provision;
-import static org.ops4j.pax.exam.CoreOptions.streamBundle;
-
-import java.io.InputStream;
-import java.util.Map;
-
-import org.apache.cxf.dosgi.samples.greeter.GreeterService;
-import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
-import org.apache.cxf.dosgi.systests2.multi.customintent.AddGreetingPhraseInterceptor;
-import org.apache.cxf.dosgi.systests2.multi.customintent.CustomFeature;
-import org.apache.cxf.dosgi.systests2.multi.customintent.CustomIntentActivator;
-import org.apache.cxf.dosgi.systests2.multi.customintent.service.EmptyGreeterService;
-import org.apache.cxf.dosgi.systests2.multi.customintent.service.GreeterServiceWithCustomIntentActivator;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.ops4j.pax.exam.Configuration;
-import org.ops4j.pax.exam.Option;
-import org.ops4j.pax.exam.junit.PaxExam;
-import org.ops4j.pax.tinybundles.core.TinyBundles;
-import org.osgi.framework.Constants;
-
-@RunWith(PaxExam.class)
-public class TestCustomIntent extends AbstractDosgiTest {
-
-    @Configuration
-    public static Option[] configure() throws Exception {
-        return new Option[] //
-        {
-         basicTestOptions(), //
-         greeterInterface(), //
-         streamBundle(getCustomIntentBundle()).noStart(), //
-         provision(getServiceBundle()), 
-         //debug()
-        };
-    }
-
-    @Test
-    public void testCustomIntent() throws Exception {
-        // There should be warnings of unsatisfied intent myIntent in the log at debug level
-        //Thread.sleep(2000);
-        getBundleByName(bundleContext, "CustomIntent").start();
-        waitPort(9090);
-
-        GreeterService greeterService = createGreeterServiceProxy("http://localhost:9090/greeter");
-        Map<GreetingPhrase, String> result = greeterService.greetMe("Chris");
-        Assert.assertEquals(1, result.size());
-        GreetingPhrase phrase = result.keySet().iterator().next();
-        Assert.assertEquals("Hi from custom intent", phrase.getPhrase());
-    }
-
-    private static InputStream getCustomIntentBundle() {
-        return TinyBundles.bundle() //
-            .add(CustomIntentActivator.class) //
-            .add(CustomFeature.class) //
-            .add(AddGreetingPhraseInterceptor.class) //
-            .set(Constants.BUNDLE_SYMBOLICNAME, "CustomIntent") //
-            .set(Constants.BUNDLE_ACTIVATOR, CustomIntentActivator.class.getName())
-            .build(TinyBundles.withBnd());
-    }
-
-    private static InputStream getServiceBundle() {
-        return TinyBundles.bundle() //
-            .add(GreeterServiceWithCustomIntentActivator.class) //
-            .add(EmptyGreeterService.class) //
-            .set(Constants.BUNDLE_SYMBOLICNAME, "EmptyGreeterService") //
-            .set(Constants.BUNDLE_ACTIVATOR, GreeterServiceWithCustomIntentActivator.class.getName())
-            .build(TinyBundles.withBnd());
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestDiscoveryExport.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestDiscoveryExport.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestDiscoveryExport.java
deleted file mode 100644
index b0113fd..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestDiscoveryExport.java
+++ /dev/null
@@ -1,53 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi;
-
-import org.apache.zookeeper.ZooKeeper;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.ops4j.pax.exam.Configuration;
-import org.ops4j.pax.exam.Option;
-import org.ops4j.pax.exam.junit.PaxExam;
-
-@RunWith(PaxExam.class)
-public class TestDiscoveryExport extends AbstractDosgiTest {
-
-    private static final String GREETER_ZOOKEEPER_NODE = //
-        "/osgi/service_registry/org/apache/cxf/dosgi/samples/greeter/GreeterService/localhost#9090##greeter";
-
-    @Configuration
-    public static Option[] configure() throws Exception {
-        return new Option[] //
-        {
-         basicTestOptions(), //
-         configZKServer(), //
-         configZKConsumer(), //
-         greeterInterface(), //
-         greeterImpl(),
-        };
-    }
-
-    @Test
-    public void testDiscoveryExport() throws Exception {
-        ZooKeeper zk = createZookeeperClient();
-        assertNodeExists(zk, GREETER_ZOOKEEPER_NODE, 5000);
-        zk.close();
-    }
-
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportRestService.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportRestService.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportRestService.java
deleted file mode 100644
index 0ed885a..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportRestService.java
+++ /dev/null
@@ -1,77 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi;
-
-import static org.ops4j.pax.exam.CoreOptions.provision;
-import static org.ops4j.pax.exam.CoreOptions.systemProperty;
-
-import java.io.InputStream;
-
-import org.apache.cxf.dosgi.systests2.multi.rest.RestTranslate;
-import org.apache.cxf.dosgi.systests2.multi.rest.RestTranslateImpl;
-import org.apache.cxf.dosgi.systests2.multi.rest.TranslateActivator;
-import org.apache.cxf.jaxrs.client.WebClient;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.ops4j.pax.exam.Configuration;
-import org.ops4j.pax.exam.Option;
-import org.ops4j.pax.exam.junit.PaxExam;
-import org.ops4j.pax.tinybundles.core.TinyBundles;
-import org.osgi.framework.Constants;
-
-@RunWith(PaxExam.class)
-public class TestExportRestService extends AbstractDosgiTest {
-    String webPort = "9091";
-
-    @Configuration
-    public Option[] configure() throws Exception {
-        return new Option[] //
-        {//
-         basicTestOptions(), //
-         systemProperty("org.osgi.service.http.port").value(webPort), //
-         provision(getServiceBundle()),
-         //debug()
-        };
-    }
-
-    @Test
-    public void testCallService() throws Exception {
-        waitWebPage("http://localhost:" + webPort + "/cxf/translate");
-        try {
-            WebClient client = WebClient.create("http://localhost:" + webPort + "/cxf/translate/hello");
-            String result = client.get(String.class);
-            Assert.assertEquals("hallo", result);
-        } catch (Exception e) {
-            // Avoid serialization problems when just letting the exception fly
-            e.printStackTrace();
-            throw new RuntimeException(e.getMessage());
-        }
-    }
-
-    private InputStream getServiceBundle() {
-        return TinyBundles.bundle() //
-            .add(RestTranslate.class) //
-            .add(RestTranslateImpl.class) //
-            .add(TranslateActivator.class) //
-            .set(Constants.BUNDLE_SYMBOLICNAME, "RestTranslate") //
-            .set(Constants.BUNDLE_ACTIVATOR, TranslateActivator.class.getName()) //
-            .build(TinyBundles.withBnd());
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportService.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportService.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportService.java
deleted file mode 100644
index 27cc989..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportService.java
+++ /dev/null
@@ -1,117 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi;
-
-import java.io.IOException;
-import java.net.URL;
-import java.util.Map;
-
-import javax.xml.parsers.DocumentBuilder;
-import javax.xml.parsers.DocumentBuilderFactory;
-import javax.xml.parsers.ParserConfigurationException;
-
-import org.apache.cxf.dosgi.samples.greeter.GreeterData;
-import org.apache.cxf.dosgi.samples.greeter.GreeterException;
-import org.apache.cxf.dosgi.samples.greeter.GreeterService;
-import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
-import org.junit.Assert;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.ops4j.pax.exam.Configuration;
-import org.ops4j.pax.exam.Option;
-import org.ops4j.pax.exam.junit.PaxExam;
-import org.w3c.dom.Document;
-import org.w3c.dom.Element;
-import org.xml.sax.SAXException;
-
-@RunWith(PaxExam.class)
-public class TestExportService extends AbstractDosgiTest {
-
-    @Configuration
-    public static Option[] configure() throws Exception {
-        return new Option[] //
-        {//
-         basicTestOptions(), //
-         greeterInterface(), //
-         greeterImpl(), //
-         //debug(),
-        };
-    }
-
-    @Test
-    public void testAccessEndpoint() throws Exception {
-        waitPort(9090);
-        checkWsdl(new URL("http://localhost:9090/greeter?wsdl"));
-        checkServiceCall("http://localhost:9090/greeter");
-    }
-
-    private void checkServiceCall(String serviceUri) {
-        GreeterService client = GreeterServiceProxyFactory.createGreeterServiceProxy(serviceUri);
-
-        Map<GreetingPhrase, String> greetings = client.greetMe("Fred");
-        Assert.assertEquals("Fred", greetings.get(new GreetingPhrase("Hello")));
-        System.out.println("Invocation result: " + greetings);
-
-        try {
-            GreeterData gd = new GreeterDataImpl("Stranger", 11, true);
-            client.greetMe(gd);
-            Assert.fail("GreeterException has to be thrown");
-        } catch (GreeterException ex) {
-            Assert.assertEquals("Wrong exception message", "GreeterService can not greet Stranger",
-                                ex.toString());
-        }
-    }
-
-    private void checkWsdl(URL wsdlURL) throws ParserConfigurationException, SAXException, IOException {
-        DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
-        dbf.setNamespaceAware(true);
-        dbf.setValidating(false);
-        DocumentBuilder db = dbf.newDocumentBuilder();
-        Document doc = db.parse(wsdlURL.openStream());
-        Element el = doc.getDocumentElement();
-        Assert.assertEquals("definitions", el.getLocalName());
-        Assert.assertEquals("http://schemas.xmlsoap.org/wsdl/", el.getNamespaceURI());
-        Assert.assertEquals("GreeterService", el.getAttribute("name"));
-    }
-
-    class GreeterDataImpl implements GreeterData {
-
-        private String name;
-        private int age;
-        private boolean exception;
-
-        GreeterDataImpl(String n, int a, boolean ex) {
-            name = n;
-            age = a;
-            exception = ex;
-        }
-
-        public String getName() {
-            return name;
-        }
-
-        public int getAge() {
-            return age;
-        }
-
-        public boolean isException() {
-            return exception;
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestImportService.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestImportService.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestImportService.java
deleted file mode 100644
index 9e435a8..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestImportService.java
+++ /dev/null
@@ -1,104 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi;
-
-import static org.ops4j.pax.exam.CoreOptions.provision;
-import static org.ops4j.pax.exam.CoreOptions.systemProperty;
-
-import java.io.InputStream;
-import java.util.Map;
-
-import javax.inject.Inject;
-
-import org.apache.cxf.aegis.databinding.AegisDatabinding;
-import org.apache.cxf.dosgi.samples.greeter.GreeterService;
-import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
-import org.apache.cxf.dosgi.systests2.multi.importservice.SimpleGreeter;
-import org.apache.cxf.endpoint.Server;
-import org.apache.cxf.frontend.ServerFactoryBean;
-import org.junit.After;
-import org.junit.Assert;
-import org.junit.Before;
-import org.junit.Test;
-import org.junit.runner.RunWith;
-import org.ops4j.pax.exam.Configuration;
-import org.ops4j.pax.exam.Option;
-import org.ops4j.pax.exam.junit.PaxExam;
-import org.ops4j.pax.tinybundles.core.TinyBundles;
-import org.osgi.framework.Constants;
-
-@RunWith(PaxExam.class)
-public class TestImportService extends AbstractDosgiTest {
-    @Inject
-    GreeterService greeterService;
-    private Server server;
-
-    @Configuration
-    public static Option[] configure() throws Exception {
-        return new Option[] //
-        {//
-         basicTestOptions(), //
-         greeterInterface(), //
-         provision(createServiceConsumerBundle()), //
-         // increase for debugging
-         systemProperty("org.apache.cxf.dosgi.test.serviceWaitTimeout")
-             .value(System.getProperty("org.apache.cxf.dosgi.test.serviceWaitTimeout", "200")),
-        };
-    }
-
-    protected static InputStream createServiceConsumerBundle() {
-        return TinyBundles.bundle() //
-            .add("OSGI-INF/remote-service/remote-services.xml",
-                 TestImportService.class.getResource("/rs-test1.xml")) //
-            .set(Constants.BUNDLE_SYMBOLICNAME, "importConfig") //
-            .build(TinyBundles.withBnd());
-    }
-
-    @Before
-    public void createCXFService() {
-        server = publishTestGreeter();
-    }
-
-    @Test
-    public void testClientConsumer() throws Exception {
-        Map<GreetingPhrase, String> result = greeterService.greetMe("OSGi");
-        GreetingPhrase phrase = result.keySet().iterator().next();
-        Assert.assertEquals("Hi", phrase.getPhrase());
-    }
-
-    @After
-    public void stopCXFService() {
-        server.stop();
-    }
-
-    private Server publishTestGreeter() {
-        ClassLoader cl = Thread.currentThread().getContextClassLoader();
-        try {
-            Thread.currentThread().setContextClassLoader(ServerFactoryBean.class.getClassLoader());
-            ServerFactoryBean factory = new ServerFactoryBean();
-            factory.setServiceClass(GreeterService.class);
-            factory.setAddress("http://localhost:9191/grrr");
-            factory.getServiceFactory().setDataBinding(new AegisDatabinding());
-            factory.setServiceBean(new SimpleGreeter());
-            return factory.create();
-        } finally {
-            Thread.currentThread().setContextClassLoader(cl);
-        }
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/AddGreetingPhraseInterceptor.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/AddGreetingPhraseInterceptor.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/AddGreetingPhraseInterceptor.java
deleted file mode 100644
index a3a19be..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/AddGreetingPhraseInterceptor.java
+++ /dev/null
@@ -1,44 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.customintent;
-
-import java.util.List;
-import java.util.Map;
-
-import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
-import org.apache.cxf.helpers.CastUtils;
-import org.apache.cxf.interceptor.Fault;
-import org.apache.cxf.message.Message;
-import org.apache.cxf.message.MessageContentsList;
-import org.apache.cxf.phase.AbstractPhaseInterceptor;
-
-public final class AddGreetingPhraseInterceptor extends AbstractPhaseInterceptor<Message> {
-
-    AddGreetingPhraseInterceptor(String phase) {
-        super(phase);
-    }
-
-    public void handleMessage(Message message) throws Fault {
-        MessageContentsList contents = (MessageContentsList) message.getContent(List.class);
-        Map<GreetingPhrase, String> result = CastUtils.cast((Map<?, ?>)contents.get(0));
-        result.put(new GreetingPhrase("Hi from custom intent"), "customintent");
-        //Object content1 = contents.iterator().next();
-        System.out.println(message);
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomFeature.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomFeature.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomFeature.java
deleted file mode 100644
index abac14f..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomFeature.java
+++ /dev/null
@@ -1,33 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.customintent;
-
-import org.apache.cxf.Bus;
-import org.apache.cxf.feature.AbstractFeature;
-import org.apache.cxf.interceptor.InterceptorProvider;
-import org.apache.cxf.phase.Phase;
-
-public final class CustomFeature extends AbstractFeature {
-
-    @Override
-    protected void initializeProvider(InterceptorProvider provider, Bus bus) {
-        provider.getOutInterceptors().add(0, new AddGreetingPhraseInterceptor(Phase.USER_LOGICAL));
-        super.initializeProvider(provider, bus);
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomIntentActivator.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomIntentActivator.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomIntentActivator.java
deleted file mode 100644
index ca4efda..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomIntentActivator.java
+++ /dev/null
@@ -1,37 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.customintent;
-
-import java.util.Dictionary;
-import java.util.Hashtable;
-
-import org.osgi.framework.BundleActivator;
-import org.osgi.framework.BundleContext;
-
-public class CustomIntentActivator implements BundleActivator {
-
-    public void start(BundleContext context) throws Exception {
-        Dictionary<String, String> props = new Hashtable<String, String>();
-        props.put("org.apache.cxf.dosgi.IntentName", "myIntent");
-        context.registerService(Object.class.getName(), new CustomFeature(), props);
-    }
-
-    public void stop(BundleContext context) throws Exception {
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/EmptyGreeterService.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/EmptyGreeterService.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/EmptyGreeterService.java
deleted file mode 100644
index 2c0108d..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/EmptyGreeterService.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.customintent.service;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.apache.cxf.dosgi.samples.greeter.GreeterData;
-import org.apache.cxf.dosgi.samples.greeter.GreeterException;
-import org.apache.cxf.dosgi.samples.greeter.GreeterService;
-import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
-
-public final class EmptyGreeterService implements GreeterService {
-
-    /**
-     * Return an empty array. Our custom intent should add a GreetingPhrase
-     */
-    public GreetingPhrase[] greetMe(GreeterData name) throws GreeterException {
-        return new GreetingPhrase[]{};
-    }
-
-    public Map<GreetingPhrase, String> greetMe(String name) {
-        return new HashMap<GreetingPhrase, String>();
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/GreeterServiceWithCustomIntentActivator.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/GreeterServiceWithCustomIntentActivator.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/GreeterServiceWithCustomIntentActivator.java
deleted file mode 100644
index bcf6016..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/GreeterServiceWithCustomIntentActivator.java
+++ /dev/null
@@ -1,42 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.customintent.service;
-
-import java.util.Dictionary;
-import java.util.Hashtable;
-
-import org.apache.cxf.dosgi.samples.greeter.GreeterService;
-import org.osgi.framework.BundleActivator;
-import org.osgi.framework.BundleContext;
-import org.osgi.service.remoteserviceadmin.RemoteConstants;
-
-public class GreeterServiceWithCustomIntentActivator implements BundleActivator {
-
-    public void start(BundleContext context) throws Exception {
-        Dictionary<String, String> props = new Hashtable<String, String>();
-        props.put(RemoteConstants.SERVICE_EXPORTED_INTERFACES, "*");
-        props.put(RemoteConstants.SERVICE_EXPORTED_CONFIGS, "org.apache.cxf.ws");
-        props.put("org.apache.cxf.ws.address", "http://localhost:9090/greeter");
-        props.put(RemoteConstants.SERVICE_EXPORTED_INTENTS, "myIntent");
-        context.registerService(GreeterService.class.getName(), new EmptyGreeterService(), props);
-    }
-
-    public void stop(BundleContext context) throws Exception {
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/importservice/SimpleGreeter.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/importservice/SimpleGreeter.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/importservice/SimpleGreeter.java
deleted file mode 100644
index e39c315..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/importservice/SimpleGreeter.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.importservice;
-
-import java.util.HashMap;
-import java.util.Map;
-
-import org.apache.cxf.dosgi.samples.greeter.GreeterData;
-import org.apache.cxf.dosgi.samples.greeter.GreeterException;
-import org.apache.cxf.dosgi.samples.greeter.GreeterService;
-import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
-
-public class SimpleGreeter implements GreeterService {
-
-    public Map<GreetingPhrase, String> greetMe(String name) {
-        Map<GreetingPhrase, String> m = new HashMap<GreetingPhrase, String>();
-        GreetingPhrase gp = new GreetingPhrase("Hi");
-        m.put(gp, name);
-        return m;
-    }
-
-    public GreetingPhrase[] greetMe(GreeterData gd) throws GreeterException {
-        throw new GreeterException("TestGreeter");
-    }
-}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslate.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslate.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslate.java
deleted file mode 100644
index 3a55c0e..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslate.java
+++ /dev/null
@@ -1,34 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.rest;
-
-import javax.ws.rs.GET;
-import javax.ws.rs.Path;
-import javax.ws.rs.PathParam;
-
-public interface RestTranslate {
-
-    @GET
-    String englishWords();
-
-    @GET
-    @Path("/{word}")
-    String getTranslation(@PathParam("word") String word);
-
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslateImpl.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslateImpl.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslateImpl.java
deleted file mode 100644
index 640b0c9..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslateImpl.java
+++ /dev/null
@@ -1,41 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.rest;
-
-import java.util.HashMap;
-import java.util.Map;
-
-public class RestTranslateImpl implements RestTranslate {
-    Map<String, String> translation;
-    
-    public RestTranslateImpl() {
-        translation = new HashMap<String, String>();
-        translation.put("hello", "hallo");
-    }
-    
-    @Override
-    public String englishWords() {
-        return translation.keySet().toString();
-    }
-    
-    @Override
-    public String getTranslation(String word) {
-        return translation.get(word);
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/TranslateActivator.java
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/TranslateActivator.java b/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/TranslateActivator.java
deleted file mode 100644
index a6b1892..0000000
--- a/systests2/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/TranslateActivator.java
+++ /dev/null
@@ -1,40 +0,0 @@
-/**
- * Licensed to the Apache Software Foundation (ASF) under one
- * or more contributor license agreements. See the NOTICE file
- * distributed with this work for additional information
- * regarding copyright ownership. The ASF licenses this file
- * to you under the Apache License, Version 2.0 (the
- * "License"); you may not use this file except in compliance
- * with the License. You may obtain a copy of the License at
- *
- * http://www.apache.org/licenses/LICENSE-2.0
- *
- * Unless required by applicable law or agreed to in writing,
- * software distributed under the License is distributed on an
- * "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
- * KIND, either express or implied. See the License for the
- * specific language governing permissions and limitations
- * under the License.
- */
-package org.apache.cxf.dosgi.systests2.multi.rest;
-
-import java.util.Dictionary;
-import java.util.Hashtable;
-
-import org.osgi.framework.BundleActivator;
-import org.osgi.framework.BundleContext;
-import org.osgi.service.remoteserviceadmin.RemoteConstants;
-
-public class TranslateActivator implements BundleActivator {
-
-    public void start(BundleContext context) throws Exception {
-        Dictionary<String, String> props = new Hashtable<String, String>();
-        props.put(RemoteConstants.SERVICE_EXPORTED_INTERFACES, "*");
-        props.put(RemoteConstants.SERVICE_EXPORTED_CONFIGS, "org.apache.cxf.rs");
-        props.put("org.apache.cxf.rs.address", "/translate");
-        context.registerService(RestTranslate.class, new RestTranslateImpl(), props);
-    }
-
-    public void stop(BundleContext context) throws Exception {
-    }
-}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/resources/cfg/org.ops4j.pax.logging.cfg
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/resources/cfg/org.ops4j.pax.logging.cfg b/systests2/multi-bundle/src/test/resources/cfg/org.ops4j.pax.logging.cfg
deleted file mode 100644
index b081a42..0000000
--- a/systests2/multi-bundle/src/test/resources/cfg/org.ops4j.pax.logging.cfg
+++ /dev/null
@@ -1,7 +0,0 @@
-log4j.rootLogger=INFO, stdout
-log4j.logger.org.apache.cxf.bus.blueprint=ERROR
-log4j.logger.org.apache.cxf.bus.osgi.CXFActivator=WARN
-
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=%d{ISO8601} | %-5.5p | %40.40c | %m%n

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/resources/log4j.properties
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/resources/log4j.properties b/systests2/multi-bundle/src/test/resources/log4j.properties
deleted file mode 100644
index 37ce342..0000000
--- a/systests2/multi-bundle/src/test/resources/log4j.properties
+++ /dev/null
@@ -1,9 +0,0 @@
-log4j.rootLogger=INFO, stdout
-
-log4j.appender.stdout=org.apache.log4j.ConsoleAppender
-log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
-log4j.appender.stdout.layout.ConversionPattern=%d{ISO8601} | %-5.5p | %40.40c | %m%n
-
-log4j.logger.org.ops4j.pax.scanner=WARN
-log4j.logger.org.ops4j.pax.runner=WARN
-log4j.logger.org.ops4j.pax.url=WARN

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/src/test/resources/rs-test1.xml
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/src/test/resources/rs-test1.xml b/systests2/multi-bundle/src/test/resources/rs-test1.xml
deleted file mode 100644
index 7392d24..0000000
--- a/systests2/multi-bundle/src/test/resources/rs-test1.xml
+++ /dev/null
@@ -1,28 +0,0 @@
-<?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.
-  -->
-<endpoint-descriptions xmlns="http://www.osgi.org/xmlns/rsa/v1.0.0"
-  xmlns:other="http://www.acme.org/xmlns/other/v1.0.0">
-  <endpoint-description>
-    <property name="objectClass">
-      <array>
-        <value>org.apache.cxf.dosgi.samples.greeter.GreeterService</value>
-      </array>
-    </property>
-    <property name="endpoint.id">http://localhost:9191/grrr</property>
-    <property name="service.imported.configs">org.apache.cxf.ws</property>
-  </endpoint-description>
-</endpoint-descriptions>
-

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/pom.xml
----------------------------------------------------------------------
diff --git a/systests2/pom.xml b/systests2/pom.xml
deleted file mode 100644
index 423b338..0000000
--- a/systests2/pom.xml
+++ /dev/null
@@ -1,41 +0,0 @@
-<?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.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-
-    <modelVersion>4.0.0</modelVersion>
-
-    <parent>
-        <groupId>org.apache.cxf.dosgi</groupId>
-        <artifactId>cxf-dosgi-ri-parent</artifactId>
-        <version>2.0-SNAPSHOT</version>
-        <relativePath>../parent/pom.xml</relativePath>
-    </parent>
-
-    <groupId>org.apache.cxf.dosgi.systests</groupId>
-    <artifactId>cxf-dosgi-ri-systests2</artifactId>
-    <version>2.0-SNAPSHOT</version>
-    <packaging>pom</packaging>
-
-    <name>Distributed OSGi System Tests</name>
-
-    <modules>
-        <module>multi-bundle</module>
-    </modules>
-</project>


[2/3] cxf-dosgi git commit: Rename systests2 to itests to make it more similar to other projects

Posted by cs...@apache.org.
Rename systests2 to itests to make it more similar to other projects


Project: http://git-wip-us.apache.org/repos/asf/cxf-dosgi/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf-dosgi/commit/052cccc7
Tree: http://git-wip-us.apache.org/repos/asf/cxf-dosgi/tree/052cccc7
Diff: http://git-wip-us.apache.org/repos/asf/cxf-dosgi/diff/052cccc7

Branch: refs/heads/master
Commit: 052cccc7f678f53b936272039c3bed6f3bc85c74
Parents: 1fef305
Author: Christian Schneider <ch...@die-schneider.net>
Authored: Wed Jul 6 11:59:37 2016 +0200
Committer: Christian Schneider <ch...@die-schneider.net>
Committed: Wed Jul 6 11:59:37 2016 +0200

----------------------------------------------------------------------
 itests/multi-bundle/pom.xml                     | 230 +++++++++++++++++
 .../systests2/multi/AbstractDosgiTest.java      | 248 +++++++++++++++++++
 .../multi/GreeterServiceProxyFactory.java       |  44 ++++
 .../dosgi/systests2/multi/MultiBundleTools.java | 102 ++++++++
 .../dosgi/systests2/multi/TestCustomIntent.java |  91 +++++++
 .../systests2/multi/TestDiscoveryExport.java    |  53 ++++
 .../systests2/multi/TestExportRestService.java  |  77 ++++++
 .../systests2/multi/TestExportService.java      | 117 +++++++++
 .../systests2/multi/TestImportService.java      | 104 ++++++++
 .../AddGreetingPhraseInterceptor.java           |  44 ++++
 .../multi/customintent/CustomFeature.java       |  33 +++
 .../customintent/CustomIntentActivator.java     |  37 +++
 .../service/EmptyGreeterService.java            |  41 +++
 ...GreeterServiceWithCustomIntentActivator.java |  42 ++++
 .../multi/importservice/SimpleGreeter.java      |  41 +++
 .../systests2/multi/rest/RestTranslate.java     |  34 +++
 .../systests2/multi/rest/RestTranslateImpl.java |  41 +++
 .../multi/rest/TranslateActivator.java          |  40 +++
 .../resources/cfg/org.ops4j.pax.logging.cfg     |   7 +
 .../src/test/resources/log4j.properties         |   9 +
 .../src/test/resources/rs-test1.xml             |  28 +++
 itests/pom.xml                                  |  41 +++
 pom.xml                                         |   2 +-
 systests2/multi-bundle/pom.xml                  | 230 -----------------
 .../systests2/multi/AbstractDosgiTest.java      | 248 -------------------
 .../multi/GreeterServiceProxyFactory.java       |  44 ----
 .../dosgi/systests2/multi/MultiBundleTools.java | 102 --------
 .../dosgi/systests2/multi/TestCustomIntent.java |  91 -------
 .../systests2/multi/TestDiscoveryExport.java    |  53 ----
 .../systests2/multi/TestExportRestService.java  |  77 ------
 .../systests2/multi/TestExportService.java      | 117 ---------
 .../systests2/multi/TestImportService.java      | 104 --------
 .../AddGreetingPhraseInterceptor.java           |  44 ----
 .../multi/customintent/CustomFeature.java       |  33 ---
 .../customintent/CustomIntentActivator.java     |  37 ---
 .../service/EmptyGreeterService.java            |  41 ---
 ...GreeterServiceWithCustomIntentActivator.java |  42 ----
 .../multi/importservice/SimpleGreeter.java      |  41 ---
 .../systests2/multi/rest/RestTranslate.java     |  34 ---
 .../systests2/multi/rest/RestTranslateImpl.java |  41 ---
 .../multi/rest/TranslateActivator.java          |  40 ---
 .../resources/cfg/org.ops4j.pax.logging.cfg     |   7 -
 .../src/test/resources/log4j.properties         |   9 -
 .../src/test/resources/rs-test1.xml             |  28 ---
 systests2/pom.xml                               |  41 ---
 45 files changed, 1505 insertions(+), 1505 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/pom.xml
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/pom.xml b/itests/multi-bundle/pom.xml
new file mode 100644
index 0000000..71be6a5
--- /dev/null
+++ b/itests/multi-bundle/pom.xml
@@ -0,0 +1,230 @@
+<?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.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.cxf.dosgi</groupId>
+        <artifactId>cxf-dosgi-ri-parent</artifactId>
+        <version>2.0-SNAPSHOT</version>
+        <relativePath>../../parent/pom.xml</relativePath>
+    </parent>
+
+    <groupId>org.apache.cxf.dosgi.systests</groupId>
+    <artifactId>cxf-dosgi-ri-itests-multibundle</artifactId>
+    <packaging>jar</packaging>
+    <name>Distributed OSGi System Tests Multi-Bundle</name>
+    
+    <properties>
+        <topDirectoryLocation>../..</topDirectoryLocation>
+    </properties>
+    
+    <!-- 
+        When changing code make sure to run the distro before testing
+        or you will be testing the old code.
+     
+     -->
+
+    <dependencies>
+        <!-- Pax Exam -->
+        <dependency>
+            <groupId>org.apache.geronimo.specs</groupId>
+            <artifactId>geronimo-atinject_1.0_spec</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.ops4j.pax.exam</groupId>
+            <artifactId>pax-exam-junit4</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.ops4j.pax.exam</groupId>
+            <artifactId>pax-exam-inject</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.ops4j.pax.exam</groupId>
+            <artifactId>pax-exam-cm</artifactId>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.ops4j.pax.exam</groupId>
+            <artifactId>pax-exam-container-forked</artifactId>
+        </dependency>
+        <dependency>
+            <groupId>org.ops4j.pax.exam</groupId>
+            <artifactId>pax-exam-link-mvn</artifactId>
+            <scope>test</scope>
+        </dependency>
+        
+        <dependency>
+            <groupId>org.ops4j.pax.url</groupId>
+            <artifactId>pax-url-aether</artifactId>
+            <version>2.4.5</version>
+        </dependency>
+
+
+        <dependency>
+            <groupId>org.eclipse.tycho</groupId>
+            <artifactId>org.eclipse.osgi</artifactId>
+        </dependency>
+        <!-- 
+        <dependency>
+            <groupId>org.apache.felix</groupId>
+            <artifactId>org.apache.felix.framework</artifactId>
+            <scope>test</scope>
+        </dependency>
+         -->
+
+        <!-- CXF -->
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-core</artifactId>
+            <version>${cxf.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-bindings-soap</artifactId>
+            <version>${cxf.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-transports-http-jetty</artifactId>
+            <version>${cxf.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-frontend-jaxrs</artifactId>
+            <version>${cxf.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-rs-client</artifactId>
+            <version>${cxf.version}</version>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf</groupId>
+            <artifactId>cxf-rt-databinding-aegis</artifactId>
+            <version>${cxf.version}</version>
+        </dependency>
+
+        <dependency>
+            <groupId>org.apache.zookeeper</groupId>
+            <artifactId>zookeeper</artifactId>
+            <version>${zookeeper.version}</version>
+            <exclusions>
+                <exclusion>
+                    <groupId>com.sun.jdmk</groupId>
+                    <artifactId>jmxtools</artifactId>
+                </exclusion>
+                <exclusion>
+                    <groupId>com.sun.jmx</groupId>
+                    <artifactId>jmxri</artifactId>
+                </exclusion>
+            </exclusions>
+        </dependency>
+        
+        <!-- Samples -->
+        <dependency>
+            <groupId>org.apache.cxf.dosgi.samples</groupId>
+            <artifactId>cxf-dosgi-ri-samples-greeter-impl</artifactId>
+            <version>${project.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf.dosgi.samples</groupId>
+            <artifactId>cxf-dosgi-ri-samples-greeter-interface</artifactId>
+            <version>${project.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf.dosgi.samples</groupId>
+            <artifactId>cxf-dosgi-ri-samples-greeter-rest-impl</artifactId>
+            <version>${project.version}</version>
+            <scope>test</scope>
+        </dependency>
+        <dependency>
+            <groupId>org.apache.cxf.dosgi.samples</groupId>
+            <artifactId>cxf-dosgi-ri-samples-greeter-rest-interface</artifactId>
+            <version>${project.version}</version>
+            <scope>test</scope>
+        </dependency>
+
+        <dependency>
+            <groupId>junit</groupId>
+            <artifactId>junit</artifactId>
+            <scope>test</scope>
+        </dependency>
+    </dependencies>
+
+    <build>
+        <plugins>
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-dependency-plugin</artifactId>
+                <executions>
+                    <execution>
+                        <id>unpack</id>
+                        <phase>generate-resources</phase>
+                        <goals>
+                            <goal>unpack</goal>
+                        </goals>
+                        <configuration>
+                            <artifactItems>
+                                <artifactItem>
+                                    <groupId>org.apache.cxf.dosgi</groupId>
+                                    <artifactId>cxf-dosgi-ri-multibundle-distribution</artifactId>
+                                    <version>${project.version}</version>
+                                    <type>zip</type>
+                                    <classifier>dir</classifier>
+                                </artifactItem>
+                            </artifactItems>
+                        </configuration>
+                    </execution>
+                </executions>
+            </plugin>
+            
+            <plugin>
+                <groupId>org.apache.servicemix.tooling</groupId>
+                <artifactId>depends-maven-plugin</artifactId>
+                <version>1.3.1</version>
+                <executions>
+                    <execution>
+                        <id>generate-depends-file</id>
+                        <goals>
+                            <goal>generate-depends-file</goal>
+                        </goals>
+                    </execution>
+                </executions>
+            </plugin>
+
+            <plugin>
+                <groupId>org.apache.maven.plugins</groupId>
+                <artifactId>maven-surefire-plugin</artifactId>
+                <configuration>
+                    <systemPropertyVariables>
+                        <!-- <org.apache.cxf.dosgi.test.debug.port>5005</org.apache.cxf.dosgi.test.debug.port> 
+                            <org.apache.cxf.dosgi.test.serviceWaitTimeout>180</org.apache.cxf.dosgi.test.serviceWaitTimeout> -->
+                        <java.util.logging.config.file>${project.build.directory}/test-classes/logging.properties</java.util.logging.config.file>
+                    </systemPropertyVariables>
+                </configuration>
+            </plugin>
+        </plugins>
+    </build>
+</project>

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
new file mode 100644
index 0000000..383d7e9
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/AbstractDosgiTest.java
@@ -0,0 +1,248 @@
+/**
+ * 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.dosgi.systests2.multi;
+
+import static org.ops4j.pax.exam.CoreOptions.composite;
+import static org.ops4j.pax.exam.CoreOptions.frameworkStartLevel;
+import static org.ops4j.pax.exam.CoreOptions.mavenBundle;
+import static org.ops4j.pax.exam.CoreOptions.systemProperty;
+import static org.ops4j.pax.exam.cm.ConfigurationAdminOptions.newConfiguration;
+
+import java.io.File;
+import java.io.IOException;
+import java.net.ConnectException;
+import java.net.HttpURLConnection;
+import java.net.InetSocketAddress;
+import java.net.MalformedURLException;
+import java.net.ServerSocket;
+import java.net.Socket;
+import java.net.URL;
+import java.util.Collection;
+import java.util.concurrent.TimeoutException;
+
+import javax.inject.Inject;
+
+import org.apache.zookeeper.ZooKeeper;
+import org.apache.zookeeper.data.Stat;
+import org.junit.Assert;
+import org.junit.BeforeClass;
+import org.ops4j.pax.exam.CoreOptions;
+import org.ops4j.pax.exam.Option;
+import org.ops4j.pax.exam.cm.ConfigurationAdminOptions;
+import org.ops4j.pax.exam.options.MavenArtifactProvisionOption;
+import org.ops4j.pax.exam.options.extra.VMOption;
+import org.osgi.framework.Bundle;
+import org.osgi.framework.BundleContext;
+import org.osgi.framework.BundleException;
+import org.osgi.framework.ServiceReference;
+
+public class AbstractDosgiTest {
+    static final int ZK_PORT = 35101;
+    private static final int TIMEOUT = 20;
+    
+    @Inject
+    BundleContext bundleContext;
+    
+    @BeforeClass
+    public static void log() {
+        System.out.println("-----------------------------------------------------------------");
+    }
+    
+
+    /**
+     * Sleeps for a short interval, throwing an exception if timeout has been reached. Used to facilitate a
+     * retry interval with timeout when used in a loop.
+     *
+     * @param startTime the start time of the entire operation in milliseconds
+     * @param timeout the timeout duration for the entire operation in seconds
+     * @param message the error message to use when timeout occurs
+     * @throws InterruptedException if interrupted while sleeping
+     */
+    private static void sleepOrTimeout(long startTime, long timeout, String message)
+        throws InterruptedException, TimeoutException {
+        timeout *= 1000; // seconds to millis
+        long elapsed = System.currentTimeMillis() - startTime;
+        long remaining = timeout - elapsed;
+        if (remaining <= 0) {
+            throw new TimeoutException(message);
+        }
+        long interval = Math.min(remaining, 1000);
+        Thread.sleep(interval);
+    }
+
+    @SuppressWarnings({
+                       "rawtypes", "unchecked"
+    })
+    protected ServiceReference waitService(BundleContext bc, Class cls, String filter, int timeout)
+        throws Exception {
+        System.out.println("Waiting for service: " + cls + " " + filter);
+        long startTime = System.currentTimeMillis();
+        while (true) {
+            Collection refs = bc.getServiceReferences(cls, filter);
+            if (refs != null && refs.size() > 0) {
+                return (ServiceReference)refs.iterator().next();
+            }
+            sleepOrTimeout(startTime, timeout, "Service not found: " + cls + " " + filter);
+        }
+    }
+
+    protected void waitPort(int port) throws Exception {
+        System.out.println("Waiting for server to appear on port: " + port);
+        long startTime = System.currentTimeMillis();
+        while (true) {
+            Socket s = null;
+            try {
+                s = new Socket((String)null, port);
+                // yep, its available
+                return;
+            } catch (IOException e) {
+                sleepOrTimeout(startTime, TIMEOUT, "Timeout waiting for port " + port);
+            } finally {
+                if (s != null) {
+                    try {
+                        s.close();
+                    } catch (IOException e) {
+                        // ignore
+                    }
+                }
+            }
+        }
+    }
+
+    protected Bundle getBundleByName(BundleContext bc, String name) {
+        for (Bundle bundle : bc.getBundles()) {
+            if (bundle.getSymbolicName().equals(name)) {
+                return bundle;
+            }
+        }
+        return null;
+    }
+
+    protected static int getFreePort() {
+        try (ServerSocket socket = new ServerSocket()) {
+            socket.setReuseAddress(true); // enables quickly reopening socket on same port
+            socket.bind(new InetSocketAddress(0)); // zero finds a free port
+            return socket.getLocalPort();
+        } catch (Exception e) {
+            throw new RuntimeException(e.getMessage(), e);
+        }
+    }
+
+    protected void waitWebPage(String urlSt) throws InterruptedException, TimeoutException {
+        System.out.println("Waiting for url " + urlSt);
+        HttpURLConnection con = null;
+        long startTime = System.currentTimeMillis();
+        while (true) {
+            try {
+                URL url = new URL(urlSt);
+                con = (HttpURLConnection)url.openConnection();
+                int status = con.getResponseCode();
+                if (status == 200) {
+                    return;
+                }
+            } catch (ConnectException e) {
+                // Ignore connection refused
+            } catch (MalformedURLException e) {
+                throw new RuntimeException(e.getMessage(), e);
+            } catch (IOException e) {
+                throw new RuntimeException(e.getMessage(), e);
+            } finally {
+                if (con != null) {
+                    con.disconnect();
+                }
+            }
+            sleepOrTimeout(startTime, TIMEOUT, "Timeout waiting for web page " + urlSt);
+        }
+    }
+
+    protected void assertBundlesStarted() {
+        for (Bundle bundle : bundleContext.getBundles()) {
+            System.out
+                .println(bundle.getSymbolicName() + ":" + bundle.getVersion() + ": " + bundle.getState());
+            if (bundle.getState() != Bundle.ACTIVE) {
+                try {
+                    bundle.start();
+                } catch (BundleException e) {
+                    e.printStackTrace();
+                }
+            }
+        }
+    }
+
+    protected ZooKeeper createZookeeperClient() throws IOException {
+        return new ZooKeeper("localhost:" + ZK_PORT, 1000, null);
+    }
+
+    protected void assertNodeExists(ZooKeeper zk, String zNode, int timeout) {
+        long endTime = System.currentTimeMillis() + timeout;
+        Stat stat = null;
+        while (stat == null && System.currentTimeMillis() < endTime) {
+            try {
+                stat = zk.exists(zNode, null);
+                Thread.sleep(200);
+            } catch (Exception e) {
+                // Ignore
+            }
+        }
+        Assert.assertNotNull("ZooKeeper node " + zNode + " was not found", stat);
+    }
+
+    protected static Option configZKConsumer() {
+        return newConfiguration("org.apache.aries.rsa.discovery.zookeeper") //
+            .put("zookeeper.host", "127.0.0.1") //
+            .put("zookeeper.port", "" + ZK_PORT).asOption();
+    }
+
+    protected static Option configZKServer() {
+        return newConfiguration("org.apache.aries.rsa.discovery.zookeeper.server")
+            .put("clientPort", "" + ZK_PORT) //
+            .asOption();
+    }
+    
+    protected static Option configLogging() {
+        return ConfigurationAdminOptions.configurationFolder(new File("src/test/resources/cfg"));
+    }
+    
+
+    protected static MavenArtifactProvisionOption greeterImpl() {
+        return mavenBundle().groupId("org.apache.cxf.dosgi.samples")
+            .artifactId("cxf-dosgi-ri-samples-greeter-impl").versionAsInProject();
+    }
+
+    protected static MavenArtifactProvisionOption greeterInterface() {
+        return mavenBundle().groupId("org.apache.cxf.dosgi.samples")
+            .artifactId("cxf-dosgi-ri-samples-greeter-interface").versionAsInProject();
+    }
+
+    protected static Option basicTestOptions() throws Exception {
+        return composite(MultiBundleTools.getDistro(), //
+                         CoreOptions.junitBundles(), //
+                         systemProperty("org.ops4j.pax.logging.DefaultServiceLog.level").value("INFO"), //
+                         systemProperty("pax.exam.osgi.unresolved.fail").value("true"), //
+                         configLogging(),
+                         frameworkStartLevel(100)
+        );
+    }
+
+
+    protected static VMOption debug() {
+        return CoreOptions.vmOption("-Xrunjdwp:transport=dt_socket,server=y,suspend=y,address=5005");
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/GreeterServiceProxyFactory.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/GreeterServiceProxyFactory.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/GreeterServiceProxyFactory.java
new file mode 100644
index 0000000..074a6f1
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/GreeterServiceProxyFactory.java
@@ -0,0 +1,44 @@
+/**
+ * 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.dosgi.systests2.multi;
+
+import org.apache.cxf.aegis.databinding.AegisDatabinding;
+import org.apache.cxf.dosgi.samples.greeter.GreeterService;
+import org.apache.cxf.frontend.ClientProxyFactoryBean;
+
+public final class GreeterServiceProxyFactory {
+
+    private GreeterServiceProxyFactory() {
+    }
+
+    protected static GreeterService createGreeterServiceProxy(String serviceUri) {
+        ClassLoader cl = Thread.currentThread().getContextClassLoader();
+        Thread.currentThread().setContextClassLoader(ClientProxyFactoryBean.class.getClassLoader());
+        try {
+            ClientProxyFactoryBean factory = new ClientProxyFactoryBean();
+            factory.setServiceClass(GreeterService.class);
+            factory.setAddress(serviceUri);
+            factory.getServiceFactory().setDataBinding(new AegisDatabinding());
+            return (GreeterService)factory.create();
+        } finally {
+            Thread.currentThread().setContextClassLoader(cl);
+        }
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/MultiBundleTools.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/MultiBundleTools.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/MultiBundleTools.java
new file mode 100644
index 0000000..70e4816
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/MultiBundleTools.java
@@ -0,0 +1,102 @@
+/**
+ * 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.dosgi.systests2.multi;
+
+import java.io.File;
+import java.io.FileInputStream;
+import java.io.FileNotFoundException;
+import java.io.IOException;
+import java.net.URL;
+import java.util.ArrayList;
+import java.util.List;
+import java.util.Map;
+import java.util.Properties;
+import java.util.TreeMap;
+
+import org.ops4j.pax.exam.CoreOptions;
+import org.ops4j.pax.exam.Option;
+
+public final class MultiBundleTools {
+
+    private MultiBundleTools() {
+    }
+    
+    private static Properties getProps(File distroDir) throws FileNotFoundException, IOException {
+        Properties p = new Properties();
+        File confFile = new File(distroDir, "conf/felix.config.properties.append");
+        p.load(new FileInputStream(confFile));
+        return p;
+    }
+
+    private static int getDistroBundles(File distroDir,
+                                        Properties props, 
+                                        Map<Integer, String> bundles) throws Exception {
+        int startLevel = Integer.parseInt(props.getProperty("org.osgi.framework.startlevel.beginning"));
+        for (int i = 0; i <= startLevel; i++) {
+            String val = props.getProperty("felix.auto.start." + i);
+            if (val != null) {
+                if (val.startsWith("file:")) {
+                    File fullDir = new File(distroDir, val.substring("file:".length()));
+                    bundles.put(i, fullDir.toURI().toASCIIString());
+                } else {
+                    if (!val.contains("org.osgi.compendium")) {
+                        // We're skipping that one as it's pulled in explicitly in the test
+                        bundles.put(i, val);
+                    }
+                }
+            }
+        }
+        return startLevel + 1; // Add 1 to start level to be on the safe side
+    }
+
+    private static File getRootDirectory() {
+        String resourceName = "/" + MultiBundleTools.class.getName().replace('.', '/') + ".class";
+        URL curURL = MultiBundleTools.class.getResource(resourceName);
+        File curFile = new File(curURL.getFile());
+        String curString = curFile.getAbsolutePath();
+        File curBase = new File(curString.substring(0, curString.length() - resourceName.length()));
+        return curBase.getParentFile().getParentFile();
+    }
+
+    private static Option[] getDistroBundleOptions() throws Exception {
+        Map<Integer, String> bundles = new TreeMap<Integer, String>();
+        File root = getRootDirectory();
+        File depRoot = new File(root, "target/dependency");
+        File distroDir = depRoot.listFiles()[0];
+        Properties props = getProps(distroDir);
+        getDistroBundles(distroDir, props, bundles);
+        List<Option> opts = new ArrayList<Option>();
+        
+        /*
+        String sysPackagesValue = props.getProperty("org.osgi.framework.system.packages");
+        opts.add(CoreOptions.frameworkProperty("org.osgi.framework.system.packages")
+                 .value(sysPackagesValue));
+        */
+
+        for (Map.Entry<Integer, String> entry : bundles.entrySet()) {
+            String bundleUri = entry.getValue();
+            opts.add(CoreOptions.bundle(bundleUri));
+        }
+        return opts.toArray(new Option[opts.size()]);
+    }
+
+    public static Option getDistro() throws Exception {
+        return CoreOptions.composite(getDistroBundleOptions());
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestCustomIntent.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestCustomIntent.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestCustomIntent.java
new file mode 100644
index 0000000..9928db0
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestCustomIntent.java
@@ -0,0 +1,91 @@
+/**
+ * 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.dosgi.systests2.multi;
+
+import static org.apache.cxf.dosgi.systests2.multi.GreeterServiceProxyFactory.createGreeterServiceProxy;
+import static org.ops4j.pax.exam.CoreOptions.provision;
+import static org.ops4j.pax.exam.CoreOptions.streamBundle;
+
+import java.io.InputStream;
+import java.util.Map;
+
+import org.apache.cxf.dosgi.samples.greeter.GreeterService;
+import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
+import org.apache.cxf.dosgi.systests2.multi.customintent.AddGreetingPhraseInterceptor;
+import org.apache.cxf.dosgi.systests2.multi.customintent.CustomFeature;
+import org.apache.cxf.dosgi.systests2.multi.customintent.CustomIntentActivator;
+import org.apache.cxf.dosgi.systests2.multi.customintent.service.EmptyGreeterService;
+import org.apache.cxf.dosgi.systests2.multi.customintent.service.GreeterServiceWithCustomIntentActivator;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.ops4j.pax.exam.Configuration;
+import org.ops4j.pax.exam.Option;
+import org.ops4j.pax.exam.junit.PaxExam;
+import org.ops4j.pax.tinybundles.core.TinyBundles;
+import org.osgi.framework.Constants;
+
+@RunWith(PaxExam.class)
+public class TestCustomIntent extends AbstractDosgiTest {
+
+    @Configuration
+    public static Option[] configure() throws Exception {
+        return new Option[] //
+        {
+         basicTestOptions(), //
+         greeterInterface(), //
+         streamBundle(getCustomIntentBundle()).noStart(), //
+         provision(getServiceBundle()), 
+         //debug()
+        };
+    }
+
+    @Test
+    public void testCustomIntent() throws Exception {
+        // There should be warnings of unsatisfied intent myIntent in the log at debug level
+        //Thread.sleep(2000);
+        getBundleByName(bundleContext, "CustomIntent").start();
+        waitPort(9090);
+
+        GreeterService greeterService = createGreeterServiceProxy("http://localhost:9090/greeter");
+        Map<GreetingPhrase, String> result = greeterService.greetMe("Chris");
+        Assert.assertEquals(1, result.size());
+        GreetingPhrase phrase = result.keySet().iterator().next();
+        Assert.assertEquals("Hi from custom intent", phrase.getPhrase());
+    }
+
+    private static InputStream getCustomIntentBundle() {
+        return TinyBundles.bundle() //
+            .add(CustomIntentActivator.class) //
+            .add(CustomFeature.class) //
+            .add(AddGreetingPhraseInterceptor.class) //
+            .set(Constants.BUNDLE_SYMBOLICNAME, "CustomIntent") //
+            .set(Constants.BUNDLE_ACTIVATOR, CustomIntentActivator.class.getName())
+            .build(TinyBundles.withBnd());
+    }
+
+    private static InputStream getServiceBundle() {
+        return TinyBundles.bundle() //
+            .add(GreeterServiceWithCustomIntentActivator.class) //
+            .add(EmptyGreeterService.class) //
+            .set(Constants.BUNDLE_SYMBOLICNAME, "EmptyGreeterService") //
+            .set(Constants.BUNDLE_ACTIVATOR, GreeterServiceWithCustomIntentActivator.class.getName())
+            .build(TinyBundles.withBnd());
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestDiscoveryExport.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestDiscoveryExport.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestDiscoveryExport.java
new file mode 100644
index 0000000..b0113fd
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestDiscoveryExport.java
@@ -0,0 +1,53 @@
+/**
+ * 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.dosgi.systests2.multi;
+
+import org.apache.zookeeper.ZooKeeper;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.ops4j.pax.exam.Configuration;
+import org.ops4j.pax.exam.Option;
+import org.ops4j.pax.exam.junit.PaxExam;
+
+@RunWith(PaxExam.class)
+public class TestDiscoveryExport extends AbstractDosgiTest {
+
+    private static final String GREETER_ZOOKEEPER_NODE = //
+        "/osgi/service_registry/org/apache/cxf/dosgi/samples/greeter/GreeterService/localhost#9090##greeter";
+
+    @Configuration
+    public static Option[] configure() throws Exception {
+        return new Option[] //
+        {
+         basicTestOptions(), //
+         configZKServer(), //
+         configZKConsumer(), //
+         greeterInterface(), //
+         greeterImpl(),
+        };
+    }
+
+    @Test
+    public void testDiscoveryExport() throws Exception {
+        ZooKeeper zk = createZookeeperClient();
+        assertNodeExists(zk, GREETER_ZOOKEEPER_NODE, 5000);
+        zk.close();
+    }
+
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportRestService.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportRestService.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportRestService.java
new file mode 100644
index 0000000..0ed885a
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportRestService.java
@@ -0,0 +1,77 @@
+/**
+ * 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.dosgi.systests2.multi;
+
+import static org.ops4j.pax.exam.CoreOptions.provision;
+import static org.ops4j.pax.exam.CoreOptions.systemProperty;
+
+import java.io.InputStream;
+
+import org.apache.cxf.dosgi.systests2.multi.rest.RestTranslate;
+import org.apache.cxf.dosgi.systests2.multi.rest.RestTranslateImpl;
+import org.apache.cxf.dosgi.systests2.multi.rest.TranslateActivator;
+import org.apache.cxf.jaxrs.client.WebClient;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.ops4j.pax.exam.Configuration;
+import org.ops4j.pax.exam.Option;
+import org.ops4j.pax.exam.junit.PaxExam;
+import org.ops4j.pax.tinybundles.core.TinyBundles;
+import org.osgi.framework.Constants;
+
+@RunWith(PaxExam.class)
+public class TestExportRestService extends AbstractDosgiTest {
+    String webPort = "9091";
+
+    @Configuration
+    public Option[] configure() throws Exception {
+        return new Option[] //
+        {//
+         basicTestOptions(), //
+         systemProperty("org.osgi.service.http.port").value(webPort), //
+         provision(getServiceBundle()),
+         //debug()
+        };
+    }
+
+    @Test
+    public void testCallService() throws Exception {
+        waitWebPage("http://localhost:" + webPort + "/cxf/translate");
+        try {
+            WebClient client = WebClient.create("http://localhost:" + webPort + "/cxf/translate/hello");
+            String result = client.get(String.class);
+            Assert.assertEquals("hallo", result);
+        } catch (Exception e) {
+            // Avoid serialization problems when just letting the exception fly
+            e.printStackTrace();
+            throw new RuntimeException(e.getMessage());
+        }
+    }
+
+    private InputStream getServiceBundle() {
+        return TinyBundles.bundle() //
+            .add(RestTranslate.class) //
+            .add(RestTranslateImpl.class) //
+            .add(TranslateActivator.class) //
+            .set(Constants.BUNDLE_SYMBOLICNAME, "RestTranslate") //
+            .set(Constants.BUNDLE_ACTIVATOR, TranslateActivator.class.getName()) //
+            .build(TinyBundles.withBnd());
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportService.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportService.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportService.java
new file mode 100644
index 0000000..27cc989
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestExportService.java
@@ -0,0 +1,117 @@
+/**
+ * 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.dosgi.systests2.multi;
+
+import java.io.IOException;
+import java.net.URL;
+import java.util.Map;
+
+import javax.xml.parsers.DocumentBuilder;
+import javax.xml.parsers.DocumentBuilderFactory;
+import javax.xml.parsers.ParserConfigurationException;
+
+import org.apache.cxf.dosgi.samples.greeter.GreeterData;
+import org.apache.cxf.dosgi.samples.greeter.GreeterException;
+import org.apache.cxf.dosgi.samples.greeter.GreeterService;
+import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
+import org.junit.Assert;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.ops4j.pax.exam.Configuration;
+import org.ops4j.pax.exam.Option;
+import org.ops4j.pax.exam.junit.PaxExam;
+import org.w3c.dom.Document;
+import org.w3c.dom.Element;
+import org.xml.sax.SAXException;
+
+@RunWith(PaxExam.class)
+public class TestExportService extends AbstractDosgiTest {
+
+    @Configuration
+    public static Option[] configure() throws Exception {
+        return new Option[] //
+        {//
+         basicTestOptions(), //
+         greeterInterface(), //
+         greeterImpl(), //
+         //debug(),
+        };
+    }
+
+    @Test
+    public void testAccessEndpoint() throws Exception {
+        waitPort(9090);
+        checkWsdl(new URL("http://localhost:9090/greeter?wsdl"));
+        checkServiceCall("http://localhost:9090/greeter");
+    }
+
+    private void checkServiceCall(String serviceUri) {
+        GreeterService client = GreeterServiceProxyFactory.createGreeterServiceProxy(serviceUri);
+
+        Map<GreetingPhrase, String> greetings = client.greetMe("Fred");
+        Assert.assertEquals("Fred", greetings.get(new GreetingPhrase("Hello")));
+        System.out.println("Invocation result: " + greetings);
+
+        try {
+            GreeterData gd = new GreeterDataImpl("Stranger", 11, true);
+            client.greetMe(gd);
+            Assert.fail("GreeterException has to be thrown");
+        } catch (GreeterException ex) {
+            Assert.assertEquals("Wrong exception message", "GreeterService can not greet Stranger",
+                                ex.toString());
+        }
+    }
+
+    private void checkWsdl(URL wsdlURL) throws ParserConfigurationException, SAXException, IOException {
+        DocumentBuilderFactory dbf = DocumentBuilderFactory.newInstance();
+        dbf.setNamespaceAware(true);
+        dbf.setValidating(false);
+        DocumentBuilder db = dbf.newDocumentBuilder();
+        Document doc = db.parse(wsdlURL.openStream());
+        Element el = doc.getDocumentElement();
+        Assert.assertEquals("definitions", el.getLocalName());
+        Assert.assertEquals("http://schemas.xmlsoap.org/wsdl/", el.getNamespaceURI());
+        Assert.assertEquals("GreeterService", el.getAttribute("name"));
+    }
+
+    class GreeterDataImpl implements GreeterData {
+
+        private String name;
+        private int age;
+        private boolean exception;
+
+        GreeterDataImpl(String n, int a, boolean ex) {
+            name = n;
+            age = a;
+            exception = ex;
+        }
+
+        public String getName() {
+            return name;
+        }
+
+        public int getAge() {
+            return age;
+        }
+
+        public boolean isException() {
+            return exception;
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestImportService.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestImportService.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestImportService.java
new file mode 100644
index 0000000..9e435a8
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/TestImportService.java
@@ -0,0 +1,104 @@
+/**
+ * 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.dosgi.systests2.multi;
+
+import static org.ops4j.pax.exam.CoreOptions.provision;
+import static org.ops4j.pax.exam.CoreOptions.systemProperty;
+
+import java.io.InputStream;
+import java.util.Map;
+
+import javax.inject.Inject;
+
+import org.apache.cxf.aegis.databinding.AegisDatabinding;
+import org.apache.cxf.dosgi.samples.greeter.GreeterService;
+import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
+import org.apache.cxf.dosgi.systests2.multi.importservice.SimpleGreeter;
+import org.apache.cxf.endpoint.Server;
+import org.apache.cxf.frontend.ServerFactoryBean;
+import org.junit.After;
+import org.junit.Assert;
+import org.junit.Before;
+import org.junit.Test;
+import org.junit.runner.RunWith;
+import org.ops4j.pax.exam.Configuration;
+import org.ops4j.pax.exam.Option;
+import org.ops4j.pax.exam.junit.PaxExam;
+import org.ops4j.pax.tinybundles.core.TinyBundles;
+import org.osgi.framework.Constants;
+
+@RunWith(PaxExam.class)
+public class TestImportService extends AbstractDosgiTest {
+    @Inject
+    GreeterService greeterService;
+    private Server server;
+
+    @Configuration
+    public static Option[] configure() throws Exception {
+        return new Option[] //
+        {//
+         basicTestOptions(), //
+         greeterInterface(), //
+         provision(createServiceConsumerBundle()), //
+         // increase for debugging
+         systemProperty("org.apache.cxf.dosgi.test.serviceWaitTimeout")
+             .value(System.getProperty("org.apache.cxf.dosgi.test.serviceWaitTimeout", "200")),
+        };
+    }
+
+    protected static InputStream createServiceConsumerBundle() {
+        return TinyBundles.bundle() //
+            .add("OSGI-INF/remote-service/remote-services.xml",
+                 TestImportService.class.getResource("/rs-test1.xml")) //
+            .set(Constants.BUNDLE_SYMBOLICNAME, "importConfig") //
+            .build(TinyBundles.withBnd());
+    }
+
+    @Before
+    public void createCXFService() {
+        server = publishTestGreeter();
+    }
+
+    @Test
+    public void testClientConsumer() throws Exception {
+        Map<GreetingPhrase, String> result = greeterService.greetMe("OSGi");
+        GreetingPhrase phrase = result.keySet().iterator().next();
+        Assert.assertEquals("Hi", phrase.getPhrase());
+    }
+
+    @After
+    public void stopCXFService() {
+        server.stop();
+    }
+
+    private Server publishTestGreeter() {
+        ClassLoader cl = Thread.currentThread().getContextClassLoader();
+        try {
+            Thread.currentThread().setContextClassLoader(ServerFactoryBean.class.getClassLoader());
+            ServerFactoryBean factory = new ServerFactoryBean();
+            factory.setServiceClass(GreeterService.class);
+            factory.setAddress("http://localhost:9191/grrr");
+            factory.getServiceFactory().setDataBinding(new AegisDatabinding());
+            factory.setServiceBean(new SimpleGreeter());
+            return factory.create();
+        } finally {
+            Thread.currentThread().setContextClassLoader(cl);
+        }
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/AddGreetingPhraseInterceptor.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/AddGreetingPhraseInterceptor.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/AddGreetingPhraseInterceptor.java
new file mode 100644
index 0000000..a3a19be
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/AddGreetingPhraseInterceptor.java
@@ -0,0 +1,44 @@
+/**
+ * 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.dosgi.systests2.multi.customintent;
+
+import java.util.List;
+import java.util.Map;
+
+import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
+import org.apache.cxf.helpers.CastUtils;
+import org.apache.cxf.interceptor.Fault;
+import org.apache.cxf.message.Message;
+import org.apache.cxf.message.MessageContentsList;
+import org.apache.cxf.phase.AbstractPhaseInterceptor;
+
+public final class AddGreetingPhraseInterceptor extends AbstractPhaseInterceptor<Message> {
+
+    AddGreetingPhraseInterceptor(String phase) {
+        super(phase);
+    }
+
+    public void handleMessage(Message message) throws Fault {
+        MessageContentsList contents = (MessageContentsList) message.getContent(List.class);
+        Map<GreetingPhrase, String> result = CastUtils.cast((Map<?, ?>)contents.get(0));
+        result.put(new GreetingPhrase("Hi from custom intent"), "customintent");
+        //Object content1 = contents.iterator().next();
+        System.out.println(message);
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomFeature.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomFeature.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomFeature.java
new file mode 100644
index 0000000..abac14f
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomFeature.java
@@ -0,0 +1,33 @@
+/**
+ * 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.dosgi.systests2.multi.customintent;
+
+import org.apache.cxf.Bus;
+import org.apache.cxf.feature.AbstractFeature;
+import org.apache.cxf.interceptor.InterceptorProvider;
+import org.apache.cxf.phase.Phase;
+
+public final class CustomFeature extends AbstractFeature {
+
+    @Override
+    protected void initializeProvider(InterceptorProvider provider, Bus bus) {
+        provider.getOutInterceptors().add(0, new AddGreetingPhraseInterceptor(Phase.USER_LOGICAL));
+        super.initializeProvider(provider, bus);
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomIntentActivator.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomIntentActivator.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomIntentActivator.java
new file mode 100644
index 0000000..ca4efda
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/CustomIntentActivator.java
@@ -0,0 +1,37 @@
+/**
+ * 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.dosgi.systests2.multi.customintent;
+
+import java.util.Dictionary;
+import java.util.Hashtable;
+
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+
+public class CustomIntentActivator implements BundleActivator {
+
+    public void start(BundleContext context) throws Exception {
+        Dictionary<String, String> props = new Hashtable<String, String>();
+        props.put("org.apache.cxf.dosgi.IntentName", "myIntent");
+        context.registerService(Object.class.getName(), new CustomFeature(), props);
+    }
+
+    public void stop(BundleContext context) throws Exception {
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/EmptyGreeterService.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/EmptyGreeterService.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/EmptyGreeterService.java
new file mode 100644
index 0000000..2c0108d
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/EmptyGreeterService.java
@@ -0,0 +1,41 @@
+/**
+ * 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.dosgi.systests2.multi.customintent.service;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.cxf.dosgi.samples.greeter.GreeterData;
+import org.apache.cxf.dosgi.samples.greeter.GreeterException;
+import org.apache.cxf.dosgi.samples.greeter.GreeterService;
+import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
+
+public final class EmptyGreeterService implements GreeterService {
+
+    /**
+     * Return an empty array. Our custom intent should add a GreetingPhrase
+     */
+    public GreetingPhrase[] greetMe(GreeterData name) throws GreeterException {
+        return new GreetingPhrase[]{};
+    }
+
+    public Map<GreetingPhrase, String> greetMe(String name) {
+        return new HashMap<GreetingPhrase, String>();
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/GreeterServiceWithCustomIntentActivator.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/GreeterServiceWithCustomIntentActivator.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/GreeterServiceWithCustomIntentActivator.java
new file mode 100644
index 0000000..bcf6016
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/customintent/service/GreeterServiceWithCustomIntentActivator.java
@@ -0,0 +1,42 @@
+/**
+ * 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.dosgi.systests2.multi.customintent.service;
+
+import java.util.Dictionary;
+import java.util.Hashtable;
+
+import org.apache.cxf.dosgi.samples.greeter.GreeterService;
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+import org.osgi.service.remoteserviceadmin.RemoteConstants;
+
+public class GreeterServiceWithCustomIntentActivator implements BundleActivator {
+
+    public void start(BundleContext context) throws Exception {
+        Dictionary<String, String> props = new Hashtable<String, String>();
+        props.put(RemoteConstants.SERVICE_EXPORTED_INTERFACES, "*");
+        props.put(RemoteConstants.SERVICE_EXPORTED_CONFIGS, "org.apache.cxf.ws");
+        props.put("org.apache.cxf.ws.address", "http://localhost:9090/greeter");
+        props.put(RemoteConstants.SERVICE_EXPORTED_INTENTS, "myIntent");
+        context.registerService(GreeterService.class.getName(), new EmptyGreeterService(), props);
+    }
+
+    public void stop(BundleContext context) throws Exception {
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/importservice/SimpleGreeter.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/importservice/SimpleGreeter.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/importservice/SimpleGreeter.java
new file mode 100644
index 0000000..e39c315
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/importservice/SimpleGreeter.java
@@ -0,0 +1,41 @@
+/**
+ * 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.dosgi.systests2.multi.importservice;
+
+import java.util.HashMap;
+import java.util.Map;
+
+import org.apache.cxf.dosgi.samples.greeter.GreeterData;
+import org.apache.cxf.dosgi.samples.greeter.GreeterException;
+import org.apache.cxf.dosgi.samples.greeter.GreeterService;
+import org.apache.cxf.dosgi.samples.greeter.GreetingPhrase;
+
+public class SimpleGreeter implements GreeterService {
+
+    public Map<GreetingPhrase, String> greetMe(String name) {
+        Map<GreetingPhrase, String> m = new HashMap<GreetingPhrase, String>();
+        GreetingPhrase gp = new GreetingPhrase("Hi");
+        m.put(gp, name);
+        return m;
+    }
+
+    public GreetingPhrase[] greetMe(GreeterData gd) throws GreeterException {
+        throw new GreeterException("TestGreeter");
+    }
+}
\ No newline at end of file

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslate.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslate.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslate.java
new file mode 100644
index 0000000..3a55c0e
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslate.java
@@ -0,0 +1,34 @@
+/**
+ * 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.dosgi.systests2.multi.rest;
+
+import javax.ws.rs.GET;
+import javax.ws.rs.Path;
+import javax.ws.rs.PathParam;
+
+public interface RestTranslate {
+
+    @GET
+    String englishWords();
+
+    @GET
+    @Path("/{word}")
+    String getTranslation(@PathParam("word") String word);
+
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslateImpl.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslateImpl.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslateImpl.java
new file mode 100644
index 0000000..640b0c9
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/RestTranslateImpl.java
@@ -0,0 +1,41 @@
+/**
+ * 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.dosgi.systests2.multi.rest;
+
+import java.util.HashMap;
+import java.util.Map;
+
+public class RestTranslateImpl implements RestTranslate {
+    Map<String, String> translation;
+    
+    public RestTranslateImpl() {
+        translation = new HashMap<String, String>();
+        translation.put("hello", "hallo");
+    }
+    
+    @Override
+    public String englishWords() {
+        return translation.keySet().toString();
+    }
+    
+    @Override
+    public String getTranslation(String word) {
+        return translation.get(word);
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/TranslateActivator.java
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/TranslateActivator.java b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/TranslateActivator.java
new file mode 100644
index 0000000..a6b1892
--- /dev/null
+++ b/itests/multi-bundle/src/test/java/org/apache/cxf/dosgi/systests2/multi/rest/TranslateActivator.java
@@ -0,0 +1,40 @@
+/**
+ * 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.dosgi.systests2.multi.rest;
+
+import java.util.Dictionary;
+import java.util.Hashtable;
+
+import org.osgi.framework.BundleActivator;
+import org.osgi.framework.BundleContext;
+import org.osgi.service.remoteserviceadmin.RemoteConstants;
+
+public class TranslateActivator implements BundleActivator {
+
+    public void start(BundleContext context) throws Exception {
+        Dictionary<String, String> props = new Hashtable<String, String>();
+        props.put(RemoteConstants.SERVICE_EXPORTED_INTERFACES, "*");
+        props.put(RemoteConstants.SERVICE_EXPORTED_CONFIGS, "org.apache.cxf.rs");
+        props.put("org.apache.cxf.rs.address", "/translate");
+        context.registerService(RestTranslate.class, new RestTranslateImpl(), props);
+    }
+
+    public void stop(BundleContext context) throws Exception {
+    }
+}

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/resources/cfg/org.ops4j.pax.logging.cfg
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/resources/cfg/org.ops4j.pax.logging.cfg b/itests/multi-bundle/src/test/resources/cfg/org.ops4j.pax.logging.cfg
new file mode 100644
index 0000000..b081a42
--- /dev/null
+++ b/itests/multi-bundle/src/test/resources/cfg/org.ops4j.pax.logging.cfg
@@ -0,0 +1,7 @@
+log4j.rootLogger=INFO, stdout
+log4j.logger.org.apache.cxf.bus.blueprint=ERROR
+log4j.logger.org.apache.cxf.bus.osgi.CXFActivator=WARN
+
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{ISO8601} | %-5.5p | %40.40c | %m%n

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/resources/log4j.properties
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/resources/log4j.properties b/itests/multi-bundle/src/test/resources/log4j.properties
new file mode 100644
index 0000000..37ce342
--- /dev/null
+++ b/itests/multi-bundle/src/test/resources/log4j.properties
@@ -0,0 +1,9 @@
+log4j.rootLogger=INFO, stdout
+
+log4j.appender.stdout=org.apache.log4j.ConsoleAppender
+log4j.appender.stdout.layout=org.apache.log4j.PatternLayout
+log4j.appender.stdout.layout.ConversionPattern=%d{ISO8601} | %-5.5p | %40.40c | %m%n
+
+log4j.logger.org.ops4j.pax.scanner=WARN
+log4j.logger.org.ops4j.pax.runner=WARN
+log4j.logger.org.ops4j.pax.url=WARN

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/multi-bundle/src/test/resources/rs-test1.xml
----------------------------------------------------------------------
diff --git a/itests/multi-bundle/src/test/resources/rs-test1.xml b/itests/multi-bundle/src/test/resources/rs-test1.xml
new file mode 100644
index 0000000..7392d24
--- /dev/null
+++ b/itests/multi-bundle/src/test/resources/rs-test1.xml
@@ -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.
+  -->
+<endpoint-descriptions xmlns="http://www.osgi.org/xmlns/rsa/v1.0.0"
+  xmlns:other="http://www.acme.org/xmlns/other/v1.0.0">
+  <endpoint-description>
+    <property name="objectClass">
+      <array>
+        <value>org.apache.cxf.dosgi.samples.greeter.GreeterService</value>
+      </array>
+    </property>
+    <property name="endpoint.id">http://localhost:9191/grrr</property>
+    <property name="service.imported.configs">org.apache.cxf.ws</property>
+  </endpoint-description>
+</endpoint-descriptions>
+

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/itests/pom.xml
----------------------------------------------------------------------
diff --git a/itests/pom.xml b/itests/pom.xml
new file mode 100644
index 0000000..6482ba7
--- /dev/null
+++ b/itests/pom.xml
@@ -0,0 +1,41 @@
+<?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.
+-->
+<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
+
+    <modelVersion>4.0.0</modelVersion>
+
+    <parent>
+        <groupId>org.apache.cxf.dosgi</groupId>
+        <artifactId>cxf-dosgi-ri-parent</artifactId>
+        <version>2.0-SNAPSHOT</version>
+        <relativePath>../parent/pom.xml</relativePath>
+    </parent>
+
+    <groupId>org.apache.cxf.dosgi.systests</groupId>
+    <artifactId>cxf-dosgi-ri-itests</artifactId>
+    <version>2.0-SNAPSHOT</version>
+    <packaging>pom</packaging>
+
+    <name>Distributed OSGi System Tests</name>
+
+    <modules>
+        <module>multi-bundle</module>
+    </modules>
+</project>

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/pom.xml
----------------------------------------------------------------------
diff --git a/pom.xml b/pom.xml
index b07da5c..ea1f430 100644
--- a/pom.xml
+++ b/pom.xml
@@ -108,7 +108,7 @@
         <module>provider-rs</module>
         <module>samples</module>
         <module>distribution</module>
-        <module>systests2</module>
+        <module>itests</module>
     </modules>
 
     <profiles>

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/052cccc7/systests2/multi-bundle/pom.xml
----------------------------------------------------------------------
diff --git a/systests2/multi-bundle/pom.xml b/systests2/multi-bundle/pom.xml
deleted file mode 100644
index 4fb0947..0000000
--- a/systests2/multi-bundle/pom.xml
+++ /dev/null
@@ -1,230 +0,0 @@
-<?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.
--->
-<project xmlns="http://maven.apache.org/POM/4.0.0" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://maven.apache.org/POM/4.0.0 http://maven.apache.org/maven-v4_0_0.xsd">
-
-    <modelVersion>4.0.0</modelVersion>
-
-    <parent>
-        <groupId>org.apache.cxf.dosgi</groupId>
-        <artifactId>cxf-dosgi-ri-parent</artifactId>
-        <version>2.0-SNAPSHOT</version>
-        <relativePath>../../parent/pom.xml</relativePath>
-    </parent>
-
-    <groupId>org.apache.cxf.dosgi.systests</groupId>
-    <artifactId>cxf-dosgi-ri-systests2-multibundle</artifactId>
-    <packaging>jar</packaging>
-    <name>Distributed OSGi System Tests Multi-Bundle</name>
-    
-    <properties>
-        <topDirectoryLocation>../..</topDirectoryLocation>
-    </properties>
-    
-    <!-- 
-        When changing code make sure to run the distro before testing
-        or you will be testing the old code.
-     
-     -->
-
-    <dependencies>
-        <!-- Pax Exam -->
-        <dependency>
-            <groupId>org.apache.geronimo.specs</groupId>
-            <artifactId>geronimo-atinject_1.0_spec</artifactId>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.ops4j.pax.exam</groupId>
-            <artifactId>pax-exam-junit4</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>org.ops4j.pax.exam</groupId>
-            <artifactId>pax-exam-inject</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>org.ops4j.pax.exam</groupId>
-            <artifactId>pax-exam-cm</artifactId>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.ops4j.pax.exam</groupId>
-            <artifactId>pax-exam-container-forked</artifactId>
-        </dependency>
-        <dependency>
-            <groupId>org.ops4j.pax.exam</groupId>
-            <artifactId>pax-exam-link-mvn</artifactId>
-            <scope>test</scope>
-        </dependency>
-        
-        <dependency>
-            <groupId>org.ops4j.pax.url</groupId>
-            <artifactId>pax-url-aether</artifactId>
-            <version>2.4.5</version>
-        </dependency>
-
-
-        <dependency>
-            <groupId>org.eclipse.tycho</groupId>
-            <artifactId>org.eclipse.osgi</artifactId>
-        </dependency>
-        <!-- 
-        <dependency>
-            <groupId>org.apache.felix</groupId>
-            <artifactId>org.apache.felix.framework</artifactId>
-            <scope>test</scope>
-        </dependency>
-         -->
-
-        <!-- CXF -->
-        <dependency>
-            <groupId>org.apache.cxf</groupId>
-            <artifactId>cxf-core</artifactId>
-            <version>${cxf.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.cxf</groupId>
-            <artifactId>cxf-rt-bindings-soap</artifactId>
-            <version>${cxf.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.cxf</groupId>
-            <artifactId>cxf-rt-transports-http-jetty</artifactId>
-            <version>${cxf.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.cxf</groupId>
-            <artifactId>cxf-rt-frontend-jaxrs</artifactId>
-            <version>${cxf.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.cxf</groupId>
-            <artifactId>cxf-rt-rs-client</artifactId>
-            <version>${cxf.version}</version>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.cxf</groupId>
-            <artifactId>cxf-rt-databinding-aegis</artifactId>
-            <version>${cxf.version}</version>
-        </dependency>
-
-        <dependency>
-            <groupId>org.apache.zookeeper</groupId>
-            <artifactId>zookeeper</artifactId>
-            <version>${zookeeper.version}</version>
-            <exclusions>
-                <exclusion>
-                    <groupId>com.sun.jdmk</groupId>
-                    <artifactId>jmxtools</artifactId>
-                </exclusion>
-                <exclusion>
-                    <groupId>com.sun.jmx</groupId>
-                    <artifactId>jmxri</artifactId>
-                </exclusion>
-            </exclusions>
-        </dependency>
-        
-        <!-- Samples -->
-        <dependency>
-            <groupId>org.apache.cxf.dosgi.samples</groupId>
-            <artifactId>cxf-dosgi-ri-samples-greeter-impl</artifactId>
-            <version>${project.version}</version>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.cxf.dosgi.samples</groupId>
-            <artifactId>cxf-dosgi-ri-samples-greeter-interface</artifactId>
-            <version>${project.version}</version>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.cxf.dosgi.samples</groupId>
-            <artifactId>cxf-dosgi-ri-samples-greeter-rest-impl</artifactId>
-            <version>${project.version}</version>
-            <scope>test</scope>
-        </dependency>
-        <dependency>
-            <groupId>org.apache.cxf.dosgi.samples</groupId>
-            <artifactId>cxf-dosgi-ri-samples-greeter-rest-interface</artifactId>
-            <version>${project.version}</version>
-            <scope>test</scope>
-        </dependency>
-
-        <dependency>
-            <groupId>junit</groupId>
-            <artifactId>junit</artifactId>
-            <scope>test</scope>
-        </dependency>
-    </dependencies>
-
-    <build>
-        <plugins>
-            <plugin>
-                <groupId>org.apache.maven.plugins</groupId>
-                <artifactId>maven-dependency-plugin</artifactId>
-                <executions>
-                    <execution>
-                        <id>unpack</id>
-                        <phase>generate-resources</phase>
-                        <goals>
-                            <goal>unpack</goal>
-                        </goals>
-                        <configuration>
-                            <artifactItems>
-                                <artifactItem>
-                                    <groupId>org.apache.cxf.dosgi</groupId>
-                                    <artifactId>cxf-dosgi-ri-multibundle-distribution</artifactId>
-                                    <version>${project.version}</version>
-                                    <type>zip</type>
-                                    <classifier>dir</classifier>
-                                </artifactItem>
-                            </artifactItems>
-                        </configuration>
-                    </execution>
-                </executions>
-            </plugin>
-            
-            <plugin>
-                <groupId>org.apache.servicemix.tooling</groupId>
-                <artifactId>depends-maven-plugin</artifactId>
-                <version>1.3.1</version>
-                <executions>
-                    <execution>
-                        <id>generate-depends-file</id>
-                        <goals>
-                            <goal>generate-depends-file</goal>
-                        </goals>
-                    </execution>
-                </executions>
-            </plugin>
-
-            <plugin>
-                <groupId>org.apache.maven.plugins</groupId>
-                <artifactId>maven-surefire-plugin</artifactId>
-                <configuration>
-                    <systemPropertyVariables>
-                        <!-- <org.apache.cxf.dosgi.test.debug.port>5005</org.apache.cxf.dosgi.test.debug.port> 
-                            <org.apache.cxf.dosgi.test.serviceWaitTimeout>180</org.apache.cxf.dosgi.test.serviceWaitTimeout> -->
-                        <java.util.logging.config.file>${project.build.directory}/test-classes/logging.properties</java.util.logging.config.file>
-                    </systemPropertyVariables>
-                </configuration>
-            </plugin>
-        </plugins>
-    </build>
-</project>


[3/3] cxf-dosgi git commit: Cleanups in constants and adding documentation

Posted by cs...@apache.org.
Cleanups in constants and adding documentation


Project: http://git-wip-us.apache.org/repos/asf/cxf-dosgi/repo
Commit: http://git-wip-us.apache.org/repos/asf/cxf-dosgi/commit/7f75cc06
Tree: http://git-wip-us.apache.org/repos/asf/cxf-dosgi/tree/7f75cc06
Diff: http://git-wip-us.apache.org/repos/asf/cxf-dosgi/diff/7f75cc06

Branch: refs/heads/master
Commit: 7f75cc0672bb24704a82b742c9f5ec4dcf7a4049
Parents: 052cccc
Author: Christian Schneider <ch...@die-schneider.net>
Authored: Wed Jul 6 11:59:57 2016 +0200
Committer: Christian Schneider <ch...@die-schneider.net>
Committed: Wed Jul 6 11:59:57 2016 +0200

----------------------------------------------------------------------
 Readme.md                                       | 32 ++++++++++++++++++++
 provider-rs/Readme.md                           | 16 ++++++++++
 .../dosgi/dsw/handlers/rest/RsConstants.java    |  4 ---
 provider-ws/Readme.md                           | 31 +++++++++++++++++++
 .../cxf/dosgi/dsw/handlers/ws/WsConstants.java  | 10 ------
 5 files changed, 79 insertions(+), 14 deletions(-)
----------------------------------------------------------------------


http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/7f75cc06/Readme.md
----------------------------------------------------------------------
diff --git a/Readme.md b/Readme.md
new file mode 100644
index 0000000..731dfa4
--- /dev/null
+++ b/Readme.md
@@ -0,0 +1,32 @@
+# CXF DOSGi
+
+Provides CXF based Distribution providers for [Aries Remote Service Admin (RSA)](http://aries.apache.org/modules/rsa.html).
+
+## Distribution Providers
+
+*   cxf-dosgi-provider-ws SOAP transport 
+*   cxf-dosgi.provider-rs REST transport
+
+## Intents
+
+A service can list the named intents it requires. It will then only be exported / imported 
+once all the intents are available. This allows for example security restrictions or logging.
+
+Example
+
+* service.exported.intents=logging
+
+See [](common "common module").
+
+## Build
+
+mvn clean install
+
+## Deployment
+
+CXF DOSGi can be deployed in three different ways
+
+*   Multi bundle distro (deprecated)
+*   Karaf feature
+*   Bndtools pom repository
+ 

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/7f75cc06/provider-rs/Readme.md
----------------------------------------------------------------------
diff --git a/provider-rs/Readme.md b/provider-rs/Readme.md
new file mode 100644
index 0000000..e387952
--- /dev/null
+++ b/provider-rs/Readme.md
@@ -0,0 +1,16 @@
+# CXF DOSGi provider RS
+
+REST based transport for Aries RSA. The exported service must be annotated with JAX-RS annotations to map the methods to HTTP verbs.
+
+# Properties
+
+*   service.exported.interfaces Interfaces to be exported or * to export all
+*   service.exported.configs org.apache.cxf.rs  
+*   org.apache.cxf.rs.address http://localhost:9090/greeter for CXF jetty transport or /greeter for servlet transport
+*   org.apache.cxf.rs.httpservice.context Can be set to use a specific http context
+*   org.apache.cxf.rs.httpservice.context.properties.* Properties wih this prefix will be set as properties of the factory. They can be used to configure features
+*   org.apache.cxf.rs.wadl.location
+
+# Sample
+
+See sample greeter-rest

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/7f75cc06/provider-rs/src/main/java/org/apache/cxf/dosgi/dsw/handlers/rest/RsConstants.java
----------------------------------------------------------------------
diff --git a/provider-rs/src/main/java/org/apache/cxf/dosgi/dsw/handlers/rest/RsConstants.java b/provider-rs/src/main/java/org/apache/cxf/dosgi/dsw/handlers/rest/RsConstants.java
index 9d13064..a6c4ceb 100644
--- a/provider-rs/src/main/java/org/apache/cxf/dosgi/dsw/handlers/rest/RsConstants.java
+++ b/provider-rs/src/main/java/org/apache/cxf/dosgi/dsw/handlers/rest/RsConstants.java
@@ -23,11 +23,7 @@ public final class RsConstants {
     public static final String RS_CONFIG_TYPE           = "org.apache.cxf.rs";
     public static final String RS_ADDRESS_PROPERTY      = RS_CONFIG_TYPE + ".address";
     public static final String RS_HTTP_SERVICE_CONTEXT  = RS_CONFIG_TYPE + ".httpservice.context";
-    public static final String RS_DATABINDING_PROP_KEY  = RS_CONFIG_TYPE + ".databinding";
     public static final String RS_CONTEXT_PROPS_PROP_KEY = RS_CONFIG_TYPE + ".context.properties";
-    public static final String RS_PROVIDER_PROP_KEY     = RS_CONFIG_TYPE + ".provider";
-    public static final String RS_PROVIDER_EXPECTED_PROP_KEY = RS_PROVIDER_PROP_KEY + ".expected";
-    public static final String RS_PROVIDER_GLOBAL_PROP_KEY = RS_PROVIDER_PROP_KEY + ".globalquery";
     public static final String RS_WADL_LOCATION         = RS_CONFIG_TYPE + ".wadl.location";
 
     private RsConstants() {

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/7f75cc06/provider-ws/Readme.md
----------------------------------------------------------------------
diff --git a/provider-ws/Readme.md b/provider-ws/Readme.md
new file mode 100644
index 0000000..e698ae2
--- /dev/null
+++ b/provider-ws/Readme.md
@@ -0,0 +1,31 @@
+# CXF DOSGi provider WS
+
+SOAP based transport for Aries RSA.
+
+# Properties
+
+
+*   service.exported.interfaces Interfaces to be exported or * to export all
+*   service.exported.configs org.apache.cxf.ws  
+*   org.apache.cxf.ws.address http://localhost:9090/greeter for CXF jetty transport or /greeter for servlet transport
+*   org.apache.cxf.ws.httpservice.context Can be set to use a specific http context
+*   org.apache.cxf.ws.context.properties.* Properties wih this prefix will be set as properties of the factory. They can be used to configure features
+
+# Modes
+
+This transport has two modes: Simple and JAX-WS. If the service is annotated using @Webservice
+then JAX-WS mode is used else simple mode is used.
+
+## Simple
+
+This mode uses the CXF simple frontend and the Aegis Databinding. It can export almost any service but is not much configureable. Aegis is also not very popular anymore. So this
+mode is more for exporting existing services and small tests.
+
+## JAX-WS
+
+If the service is annotated using @Webservice then the JAX-WS mode is activated. It uses
+the CXF JAX-WS frontend and the JAXB databinding. It can be customized using the usual annotations.
+
+# Samples
+
+See sample greeter

http://git-wip-us.apache.org/repos/asf/cxf-dosgi/blob/7f75cc06/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsConstants.java
----------------------------------------------------------------------
diff --git a/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsConstants.java b/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsConstants.java
index 6e32f1f..45c6ab8 100644
--- a/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsConstants.java
+++ b/provider-ws/src/main/java/org/apache/cxf/dosgi/dsw/handlers/ws/WsConstants.java
@@ -23,18 +23,8 @@ public final class WsConstants {
     public static final String WS_ADDRESS_PROPERTY = WS_CONFIG_TYPE + ".address";
     public static final String WS_PORT_PROPERTY = WS_CONFIG_TYPE + ".port";
     public static final String WS_HTTP_SERVICE_CONTEXT = WS_CONFIG_TYPE + ".httpservice.context";
-
-    public static final String WS_FRONTEND_PROP_KEY = WS_CONFIG_TYPE + ".frontend";
-    public static final String WS_FRONTEND_JAXWS = "jaxws";
-    public static final String WS_FRONTEND_SIMPLE = "simple";
-
     public static final String WS_CONTEXT_PROPS_PROP_KEY = WS_CONFIG_TYPE + ".context.properties";
 
-    public static final String WS_DATABINDING_PROP_KEY = WS_CONFIG_TYPE + ".databinding";
-    public static final String WS_DATABINDING_BEAN_PROP_KEY = WS_DATABINDING_PROP_KEY + ".bean";
-    public static final String WS_DATA_BINDING_JAXB = "jaxb";
-    public static final String WS_DATA_BINDING_AEGIS = "aegis";
-
     public static final String WS_WSDL_SERVICE_NAMESPACE = WS_CONFIG_TYPE + ".service.ns";
     public static final String WS_WSDL_SERVICE_NAME = WS_CONFIG_TYPE + ".service.name";
     public static final String WS_WSDL_PORT_NAME = WS_CONFIG_TYPE + ".port.name";