Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Does there exist an overview of OSGi terminology, frameworks and their relations?

I'm trying to get comfortable in the vast ecosystem of enterprise OSGi programming, but I find it very difficult to get an overview of how this technology stack is put together, which technologies build upon one another, which technologies solve what task, and how they all fit in the limited terminology I have managed to understand so far.

For example: What is the relation between Apache Felix, Equinox, Karaf, Jira OSGi, Spring DM, Aries Blueprint, Gemini Blueprint, iPOJO, Camel etc. etc...

I know Equinox is based on Felix, and that the Blueprint variants and iPOJO are somewhat related to component management, but what about Declarative Services? Is DS an alternative to Blueprint, or is Blueprint an implementation of Declarative Services?

In general, I am heavily confused, and I really need a simple overview of how common OSGi technologies in general are related.

Does anyone know of there exists such an overview - perhaps graphical - of the OSGi ecosystem?

Best regards.

like image 761
Tormod Haugene Avatar asked Nov 22 '18 12:11

Tormod Haugene


People also ask

How does the OSGi framework work?

The OSGi Framework works out all the dependencies, and calculates the independent required class path for each bundle. This approach resolves the shortcomings of plain Java class loading by ensuring that the following requirements are met: Each bundle provides visibility only to Java packages that it explicitly exports.

What is an OSGi bundle in Java?

An OSGi bundle is a Java archive file that contains Java code, resources, and a manifest that describes the bundle and its dependencies. The bundle is the unit of deployment for an application. An OSGi application groups a set of bundles to provide a coherent business logic.

What is the global class path in OSGi?

There is no global class path in OSGi. When bundles are installed into the OSGi Framework, their metadata is processed by the module layer and their declared external dependencies are reconciled against the versioned exports declared by other installed modules.

What is the unit of deployment in OSGi?

The unit of deployment in OSGi is a bundle. The modules layer is where the OSGi Framework processes the modular aspects of a bundle. The metadata that enables the OSGi Framework to do this processing is provided in a bundle manifest file. For more information about this file, see Example: OSGi bundle manifest file.


1 Answers

I don't know of a graphical representation. I can break down the few specific things you have mentioned in your post:

  1. An "OSGi Framework" is an implementation of the core OSGi specification. It would have to implement the concept of bundles, installing and resolving bundles, lifecycle, services and so on.
  2. Apache Felix is an OSGi Framework implementation.
  3. Equinox is also an OSGi Framework implementation. It is not "based on" Apache Felix but it does borrow a small amount of code from it. Equinox is the implementation of OSGi used in Eclipse etc.
  4. Karaf is essentially an application server product. It uses Felix as its core OSGi Framework implementation, and then adds a lot of extra features on the top.
  5. Jira OSGi: don't know. I believe Jira is internally implemented with OSGi but I don't know any of the details.
  6. Spring DM is an obsolete/dead project. It was a way of splitting up a Spring bean graph into a modular application, using OSGi.
  7. Blueprint is a specification published by the OSGi Alliance. It is one of the Compendium specifications, i.e. add-ons that are not required in the Core. Blueprint was inspired by Spring-DM and it standardises the idea of wiring together beans within and between bundles.
  8. Gemini Blueprint is an implementation of the Blueprint specification. Gemini started with the Spring-DM code and evolved it to comply with the (then) new specification.
  9. Aries Blueprint is also an implementation of Blueprint. It is "clean-room", i.e. implemented from scratch against the specification rather than evolved from older Spring code.
  10. Declarative Services is an OSGi specification from the Compendium. It is an alternative way to define components and to wire them together using services across bundles. Many experienced OSGi developers – including me – consider Declarative Services to be FAR superior to Blueprint. I can elaborate more on the reasons for that if you like.
  11. iPOJO is yet another different way to define components and wire them together. It does not conform to any OSGi specification.
  12. Camel is an integration library, mostly used for messaging applications. It doesn't have much to do with OSGi except that it can run under OSGi.

I hope this helps.

like image 79
Neil Bartlett Avatar answered Oct 12 '22 11:10

Neil Bartlett