Chapter 17. Scaling messaging applications with OSGi

 

This chapter covers

  • Overview of the OSGi module system
  • Reasons to combine messaging with OSGi

In this chapter, we investigate scalability of messaging applications. Of the multiple types of scalability, the most discussed is the scalability of an application at runtime, but scalability is also used in other contexts, such as the scalability of a business model and the scalability of a project. This chapter focuses on scalability at runtime and at development time. First we introduce the OSGi (Open Services Gateway initiative) module system and then we link it to messaging to show the complementary nature of the two.

Since 1998, OSGi has been primarily driven as a needed extension of Java—needed because Java’s module system is simplistic. Java loads all classes in all JARs it sees on the classpath linearly, and thereby exposes all known types on the classpath to all other known types. In large applications, this can be catastrophic, so OSGi was introduced to resolve this problem.

17.1. The OSGi module system

17.2. Accessing the Service Registry through Gemini Blueprint

17.3. Messaging between bundles

17.4. Summary