Wiring made easy using OSGi Blueprint and Apache Karaf

The OSGi Blueprint Container specification allows us to use dependency injection in our OSGi environment, declarative import and export of OSGi services, registering lifecycle listeners and wiring dependencies into our services with a few lines of XML code. In the following tutorial we’re first building an OSGi bundle classical style and afterwards take a trip into the advantages of the Blueprint specification. Our OSGi container of choice here will be Apache Karaf a lightweight container with a lot of nice features and – of course – blueprint enabled… ...

April 16, 2012 · 9 min · 1706 words · Micha Kops

How to create a simple OSGi Web Application using Maven

In this tutorial we will take a look at the development of a simple OSGi Web Application and what tools can save us some time. The Maven Bundle Plugin makes our life much easier here as does the OSGi Bundle Repository that offers some nice bundles – in our case the servlet API and an embedded Jetty web server. So lets develop some bundles .. Prerequisites You are going to need a JDK (>=5), Maven2, the Apache Felix OSGi implementation and and text editor/http://eclipse.org/[IDE] of your choice. ...

July 25, 2010 · 8 min · 1505 words · Micha Kops