MyOSGiServiceInterface service = context.getService(ref);
The Problem is that my servlet doesn't know MyOSGiServiceInterface 'cause that is defined in the OSGiBundle. In Eclipse I added a reference to the bundle Project in my Build Path. But at runtime it obviously can't find it.
To solve that Problem I played around with Export-Package: package-of-osgi-service-interface (in bundle manifest), Import-Package: package-of-osgi-service-Interface (in servlet manifest) and Dependencies: ...,deployment.MyBundle (also in servlet manifest)
But I couldn't solve it.
Whats the missing step? How can I tell JBoss to add the package containing MyOSGiServiceInterface in OSGiBundle to the class path?