Skip to end of metadata
Go to start of metadata

CXF DOSGi in Apache Karaf

Since version 1.4.0 of CXF DOSGi there is a feature for Apache Karaf which makes installing DOSGi really easy. Using the descriptions below a working demo should be up in less than 10 minutes.

Download and unpack Apache Karaf

  • Download apache karaf
  • Copy etc/ to etc/ -> This is needed in karaf 2.2.x to adjust the system package exports so CXF can install correctly
  • Unpack and start it

CXF DOSGi does not work with Karaf 2.3.0. Please use at least Karaf 2.3.1.

Installation of CXF-DOSGi

Create config "etc/org.apache.cxf.dosgi.discovery.zookeeper.cfg" with the following content:

Installation of the zookeeper Server

Create config "etc/org.apache.cxf.dosgi.discovery.zookeeper.server.cfg" with the following content:

Test installation with greeter demo

log:display should show the greeter service being exported:

Access the service transparently from a second container

  • Unpack karaf in a second directory and also start it.
  • Do the installation steps from "Installation of CXF-DOSGi"
  • Install a client to a service that is published in the first container.
  • DOSGi will automatically install a proxy for you service that calls the published service remotely over CXF
  • No labels