Skip to content
This repository has been archived by the owner on Jul 12, 2024. It is now read-only.

OSGi Integration

Thomas Diesler edited this page Oct 11, 2013 · 10 revisions

Preparing the Framework

Gravia provides a number of bundles as Maven artefacts

    <dependency>
        <groupId>org.jboss.gravia</groupId>
        <artifactId>gravia-resource</artifactId>
    </dependency>
    <dependency>
        <groupId>org.jboss.gravia</groupId>
        <artifactId>gravia-runtime-api</artifactId>
    </dependency>
    <dependency>
        <groupId>org.jboss.gravia</groupId>
        <artifactId>gravia-runtime-osgi</artifactId>
    </dependency>

Preparing a Bundle

Gravia works with already resolved Bundles that have a valid ClassLoader. In this case with the ClassLoader provided by the Framework.

Installing/Starting a Module

Before a Module becomes operational the OSGi Runtime does the following

  1. Create the global Runtime instance
  2. Install the Bundle as a Module in the Runtime
  3. Start the Module

This is done by tracking resolved Bundles in the Framework. Any Bundle can also be a Gravia Module

Stopping Stopping/Uninstalling a Module

When a bundle gets uninstalled OSGi Runtime does the following

  1. Stop the Gravia Module
  2. Uninstall the Gravia Module from the Runtime

Defining the Module

Have a look at Defining a Module

Activating the Module

Have a look at Activating a Module

Clone this wiki locally