Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

The Apache CXF Distributed OSGi subproject provides the Reference Implementation of the Distribution Provider component of the OSGi Remote Services Specification (Chapter 13 in the OSGi 4.2 Compendium Specification).
It implements the Remote Services functionality using Web Services, leveraging SOAP over HTTP and exposing the Service over a WSDL contract. Starting from version 1.1, Java interfaces can also be exposed and consumed as RESTful JAX-RS services. The 1.2 version of this project is also the Reference Implementation of the OSGi Remote Service Admin specification, chapter 122 in the OSGi 4.2 Enterprise Specification).

This page is about getting started and the demos, further links:

Getting Started

To get started, get yourself a CXF-DOSGi distribution. The following distributions are available:

Which distribution to take? That depends on what you are doing. The single-bundle distribution is a really convenient way of getting started as it provides all of Distributed OSGi plus its dependencies in one.
The multi-bundle distribution is obviously a little more work to install, but the fine-grained bundles do have an extra benefit: they allow sharing. So if your application depends on one or more of the library bundles, it can use them from the multi-bundle distribution. Similarly, the multi-bundle distribution makes it possible to update the dependency bundles - if compatible - without having to replace the Distributed OSGi bundles.

Setting up CXF/DOSGi Discovery

See the DOSGi Discovery page and the DOSGi Discovery Demo page.

The Samples

The samples directory contains these sample projects:

Sample

Description

greeter

Greeter OSGi Service exposed remotely and a Consumer invoking on it.

greeter_rest

Greeter OSGi Service exposed remotely as a RESTful service and a Consumer invoking on it. Virtually identical to a greeter sample

spring_dm

Shows how you can use Spring DM to export your beans as OSGi Services and similarly how to use Spring-DM to inject a (remote) OSGi Service.

ds

Shows how Distributed OSGi can be used with OSGi Declarative Services (DS).

discovery

Shows how to use Distributed OSGi with a dynamic Discovery system such as the one based on Zookeeper that comes with CXF/DOSGi.

iPOJO

Shows how Distributed OSGi can be used with iPOJO

The samples can be installed directly from the maven release repository (as described in the demo documentation pages), but you can also build them yourself.
To build the samples from source:

...

CXF based distribution providers for Aries Remote Service Admin (RSA). This allows to:

  • Offer and consume SOAP as well as REST based services. For declarative services CXF DOSGi is the easiest way to interact with such services.
  • Transparently communicate between OSGi containers

Familiarize yourself with CXF DOSGi by trying the examples below. Leveraging Apache Karaf it only takes a few minutes to understand and try each example.

Releases

The current release is 2.0.0. See the releases page for release informations and downloads.

Documentation

Starting with version 2.0.0 the reference documentation is written using github wiki markdown and embedded into the source repository you can find the old reference docs here.

Community

...