Osgi Activator Spring Context
The OSGi Alliance, formerly known as the Open Services Gateway initiative, is an open standards organization founded in March 1999 that originally specified and.
Servlet Context Listener Plugin Module; OSGi, Spring and the Plugin Framework. Spring DM takes the service model of OSGi and simplifies it into Spring terms.
We would like to show you a description here but the site won t allow us.
DeveloperWorks; Technical topics; SOA and web services; Technical library; OSGi and Spring, Part 1: Build and deploy OSGi bundles using Apache Felix. A step-by-step.
How to properly include Spring into an OSGified bundle
Bundle-Activator is a Manifest Header which specifies a class, implementing the org.osgi.framework.BundleActivator interface, which will be called at bundle.
Hello, OSGi, Part 1: Bundles for beginners. More like this. Hello, The Plug-in Context dialog will open. Activator.java and MANIFEST.MF.
I have a very simple OSGI app that just listens on register/unregister and sends some message to stdout.
What I have in my app is a simple Spring initialized bean. I use the maven bundle plugin to bundle the jar and put it into felix. This is an exceprt of the pom:
The project compiles just fine and can be deployed into Felix just fine, however, when the activator is called, it complains about missing dependency like that:
Unresolved constraint in bundle foo.bar.project 56 : Unable to
resolve 56.0: missing requirement 56.0 osgi.wiring.package;
osgi.wiring.package org.springframework.context version 3.1.0. version 4.0.0
In which felix complains that android-dalvik is not present, so I am completely clueless.
Any idea how to include Spring in an OSGI project without using Spring DM.
EDIT: Here is what the generated manifest complains about from web console
foo.bar.osgi foo.bar.service foobar.tracker
Imported Packages org.osgi.framework,version 1.6,2 from
org.apache.felix.framework 0 org.osgi.util.tracker,version 1.5,2
from org.apache.felix.framework 0 ERROR:
org.springframework.context,version 3.1,4 -- Cannot be resolved
ERROR: org.springframework.context.support,version 3.1,4 -- Cannot
Manifest Headers Bnd-LastModified: 1339014840268
Bundle-Activator: foo.bar.osgi.Activator
Bundle-SymbolicName: foo.bar.OSGIProject
Bundle-Version: 0.20.0.SNAPSHOT
Created-By: Apache Maven Bundle Plugin
Export-Package: foo.bar.osgi.tracker; uses: foo.bar.osgi.service,
org.osgi.util.tracker, org.osgi.framework,
foo.bar.osgi; uses: org.springframework.context.support,
org.springframework.context, org.osgi.framework, foo.bar.osgi.service
org.osgi.framework; version 1.6, 2, org.osgi.util.tracker;
version 1.5, 2, org.springframework.context; version 3.1, 4,
org.springframework.context.support; version 3.1, 4
Manifest-Version: 1.0 Tool: Bnd-1.15.0
src/main/resources/spring-beans.xml
nl.synovite.scheduled.osgi.Activator.
OSGi and Spring Update: JSR 232 is is promoted for OSGi applications; your bundle activator should configure a registry and the Spring application context.