Design

Pax Runner is made up of three types of components: Handlers, Scanners, Platforms that are assambled toegether by the Engine.
Any of the components can be used independently of each other and on the core engine itself.

Core engine

Implemented as a fake osgi engine that knows just enough to full the other types of components that they are running in an osgi framework.
It has the following basic workflow:

  1. reads the configuration file
  2. prepares configuration for the rest of components
  3. starts up the necessary url handlers and scanners (based on startup arguments & configuration defaults)
  4. starts the target platform (based on startup arguments & configuration defaults)

How does it work:

  1. The runner booter will load the defualt configuration file and merge it with the provided configuration file (if any).
  2. Based on the start up options and defaults will load the necessary url handlers and scanners using the activator class specified in the configuration
  3. Loads url handlers.
    1. Based on the --handlers option it will determine the url handlers to load
    2. As each of this handlers will register URLStreamHandler(s) it will intercept the call to bundle context and will use standard java.net.URL extensibility to install the new scheme (protocol). This mechanism is described in the Javadoc fro URLStreamHandler and in section 11.2 of core OSGi specs.
  4. Loads scanners
    1. Based on the --scanners option it will determine the scanners to load
    2. As each of this scanners will make use of bundle context to install and optionaly start the bundles it will intercept the call to BundleContext.installBundle and register those bundles for later start up.
    3. If the scanner makes use of StartlevelService for setting up the start level of the bundle it will also register this calls and use them when the actual platform is started.
  5. Start the required target platform.

URL Handlers

URL Handlers are bundles that implement the OSGi URl Handlers Service Specification. Basicaly they register new URL schemas and know how to handle those urls. There is no specific runner api that should be followed.
As part of Pax Runner the folowing additional (to standard file:, http:, https, jar) handler are implemented:

Mvn Protocol

Error rendering macro 'excerpt-include' : No link could be created for 'Pax URL - mvn'.

Wrap Protocol

Error rendering macro 'excerpt-include' : No link could be created for 'Pax URL - wrap'.

Classpath Protocol

Error rendering macro 'excerpt-include' : No link could be created for 'Pax URL - classpath'.

Ivy Protocol

Error rendering macro 'excerpt-include' : No link could be created for 'Pax URL - ivy'.

Obr Protocol

Error rendering macro 'excerpt-include' : No link could be created for 'Pax URL - obr'.

Scanners

Scanners are bundles that exposes a Scanner service that knows how to install other bundls. Basicaly they know how to obtains a list of urls to the bundles that have to be installed and uses the bundle context to install and optionaly start them. Implementations should implement and expose the simple scanner-api.
As part of Pax Runner the folowing scanners are implemented:

File Scanner

Error rendering macro 'excerpt-include' : No link could be created for 'Scanner - File'.

Maven POM Scanner

Error rendering macro 'excerpt-include' : No link could be created for 'Scanner - Maven 2 POM'.

Directory Scanner

Error rendering macro 'excerpt-include' : No link could be created for 'Scanner - Directory'.

Bundle Scanner

Error rendering macro 'excerpt-include' : No link could be created for 'Scanner - Bundle'.

Scanners work via a whiteboard pattern toegether with the Provision Extender.

Platforms

Platforms are bundles that know how to start a target osgi platform. Implementations should implement a specific pax runner platform api.
As part of Pax Runner the folowing platforms are implemented:

5.4.2. Pax Runner - Platform - Felix

Error rendering macro 'excerpt-include' : No link could be created for 'Platform - Felix'.

5.4.3. Pax Runner - Platform - Equinox

Error rendering macro 'excerpt-include' : No link could be created for 'Platform - Equinox'.

5.4.4. Pax Runner - Platform - Knopflerfish

Error rendering macro 'excerpt-include' : No link could be created for 'Platform - Knopflerfish'.

5.4.5. Pax Runner - Platform - Concierge

Error rendering macro 'excerpt-include' : No link could be created for 'Platform - Concierge'.

Platforms work via a whiteboard pattern toegether with the Platform Extender.