Skip to main content

Notice: this Wiki will be going read only early in 2024 and edits will no longer be possible. Please see: https://gitlab.eclipse.org/eclipsefdn/helpdesk/-/wikis/Wiki-shutdown-plan for the plan.

Jump to: navigation, search

Difference between revisions of "Virgo/Design/QuasiFramework"

< Virgo‎ | Design
Line 18: Line 18:
 
= Installation and Dependency Resolution =
 
= Installation and Dependency Resolution =
  
The installation use case is offline with respect to the OSGi framework state (unless and until the quasi framework state is committed to the OSGi framework) and is online with respect to the region digraph. In this case, the quasi framework contains a snapshot of the "live" OSGi framework and refers to the "live" region digraph. The live region digraph ius used because of the way the region digraph is implemented in terms of OSGi framework hooks with global effects. It was not possible to create a snapshot of the region digraph for use during resolution. Instead the quasi framework creates a temporary "coregion" to contain any quasi bundles installed into the quasi framework. Since the bundle ids of quasi bundles are not valid in the live OSGi framework, it is unlikely that the coregion could be abused even if some other part of the system noticed its existence and read its contents (i.e. the bundle ids in the coregion). The coregion is deleted when the quasi framework is cleaned up.
+
The installation use case is offline with respect to the OSGi framework state (unless and until the quasi framework state is committed to the OSGi framework) and is online with respect to the region digraph. In this case, the quasi framework contains a snapshot of the OSGi framework but refers to the "live" region digraph. The live region digraph is needed because of the region digraph is implemented using OSGi framework hooks with global effects and so it is not possible to create a snapshot of the region digraph for use during offline resolution. Instead the quasi framework creates a temporary "coregion" to contain any quasi bundles installed into the quasi framework. The coregion is connected directly to and from the user region with all resources visible in both directions. Thus the coregion's contents are equivalent to user region contents, but can easily be cleaned up by deleting the coregion. Since the bundle ids of quasi bundles are not valid in the live OSGi framework, it is unlikely that the coregion could be abused even if some other part of the system noticed its existence and read its contents (i.e. the bundle ids in the coregion). The coregion is deleted when the quasi framework is destroyed.
  
 
= Dump Analysis =
 
= Dump Analysis =
  
 
The dump analysis use case is completely offline in the sense that live state is not affected. In this case, the quasi framework contains a snapshot of the OSGi framework and region digraph that were dumped, e.g. on a resolution failure.
 
The dump analysis use case is completely offline in the sense that live state is not affected. In this case, the quasi framework contains a snapshot of the OSGi framework and region digraph that were dumped, e.g. on a resolution failure.

Revision as of 09:42, 9 April 2013

The two main use cases for the quasi framework are installing bundles into a "side state" (and automatically installing missing dependencies from the Virgo repository) and analysing a dump produced by a resolution failure.

Interfaces

The quasi framework supports the following interfaces:

  • QuasiFrameworkFactory with methods to create a quasi framework based on:
    • a snapshot of the current OSGi framework state and the region digraph, or
    • a directory containing dumps of the OSGi framework state and the region digraph.
  • QuasiFramework with methods to:
    • install a bundle into the quasi framework (as a quasi bundle, meaning it only exists in the quasi framework)
    • inquire the quasi framework
    • attempt to resolve the quasi bundles
    • diagnose why a particular quasi bundle failed to resolve
    • commit all the quasi bundles by installing corresponding bundles in the OSGi framework
    • destroy the quasi framework by deleting any associated coregion (described below).

Installation and Dependency Resolution

The installation use case is offline with respect to the OSGi framework state (unless and until the quasi framework state is committed to the OSGi framework) and is online with respect to the region digraph. In this case, the quasi framework contains a snapshot of the OSGi framework but refers to the "live" region digraph. The live region digraph is needed because of the region digraph is implemented using OSGi framework hooks with global effects and so it is not possible to create a snapshot of the region digraph for use during offline resolution. Instead the quasi framework creates a temporary "coregion" to contain any quasi bundles installed into the quasi framework. The coregion is connected directly to and from the user region with all resources visible in both directions. Thus the coregion's contents are equivalent to user region contents, but can easily be cleaned up by deleting the coregion. Since the bundle ids of quasi bundles are not valid in the live OSGi framework, it is unlikely that the coregion could be abused even if some other part of the system noticed its existence and read its contents (i.e. the bundle ids in the coregion). The coregion is deleted when the quasi framework is destroyed.

Dump Analysis

The dump analysis use case is completely offline in the sense that live state is not affected. In this case, the quasi framework contains a snapshot of the OSGi framework and region digraph that were dumped, e.g. on a resolution failure.

Back to the top