Hi, Am 24.05.2012 um 16:47 schrieb Marcel Offermans:
> On May 24, 2012, at 16:35 PM, <[email protected]> <[email protected]> wrote: > >> I'm trying to come to a more elegant solution to some hibernate and osgi >> issues. I'm somewhat familiar with the problems, i.e. I understand that >> hibernate uses some sort of dynamic class loading that short cuts the osgi >> mechanisms, thus leaving my annotated classes out of the picture. >> >> One of my issues it is that I have a felix container started in an already >> running app. I am exporting hibernate, among other things, from the host >> application to the container/system bundle so that my installed bundles can >> use it. My question is, can I also configure the container/system bundle to >> Import stuff from the installed bundles? > > No, the system bundle unfortunately cannot import anything from the installed > bundles. That is a fundamental limitation you will have to live with when > embedding an OSGi framework in an existing application. But you can, of course, go the other way around: Place the libs in a shared class loader and expose them through the system bundle to the framework, e.g. using the org.osgi.framework.system.packages.extra property. This can be set just like any Export-Package header allowing to expose versioned packages into the framework. Regards Felix > > Greetings, Marcel > > > --------------------------------------------------------------------- > To unsubscribe, e-mail: [email protected] > For additional commands, e-mail: [email protected] > --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]

