Facilitating the Spread of Knowledge and Innovation in Professional Software Development

Write for InfoQ


Choose your language

InfoQ Homepage News Spring and OSGi - A Perfect Match?

Spring and OSGi - A Perfect Match?

The Spring Framework has become a favorite of enterprise application developers in recent years. The OSGi specification and various Java implementations has also been growning in popularity. Work has recently begun to combine the power of these two complementary frameworks with a specification supported by BEA, Oracle, IBM, Eclipse, the OSGi Alliance.

The goal of Spring’s OSGi support is to make it as easy as possible to write Spring applications that can be deployed in an OSGi execution environment, and that can take advantage of the services offered by the OSGi framework. Spring’s OSGi support also makes development of OSGi applications simpler and more productive by building on the ease-of-use and power of the Spring Framework.

Among the benefits envisioned:

  • Better separation of application logic into modules
  • The ability to deploy multiple versions of a module concurrently
  • The ability to dynamically discover and use services provided by other modules in the system
  • The ability to dynamically deploy, update and undeploy modules in a running system
  • Use of the Spring Framework to instantiate, configure, assemble, and decorate components within and across modules.
  • A simple and familiar programming model for enterprise developers to exploit the features of the OSGi

An implmentation is targeted to have an initial release in Spring 2.1. Martin Lippert and Gerd Wutherich have sandbox Spring OSGi code running inside a web application using the servlet container embeddable equinox support created by the server-side equinox incubator project. Initial support will be for the Eclipse Equinox project and then expanded to other OSGi providers if possible.


Rate this Article