I run an embedded equinox 3.6.2 container and I want to make use of framework adaptor hooks. I am however unable to get it working properly. Here is what I have done:
I have created a fragment bundle with the following structure:
. |-- se | `-- nordicit | `-- osgi | `-- platformclassloading | |-- HelloHook.class | |-- HookConfiguratorImpl.class | `-- PlatformClassloadingHook.class
|-- hookconfigurators.properties `-- META-INF `-- MANIFEST.MF
I have the following fragment host manifest entry ( I have tried 3.6.2 and no version as well ): Fragment-Host: org.eclipse.osgi;bundle-version="3.4.0"
And the following hookconfigurators.properties entries: hook.configurators=se.nordicit.osgi.platformclassloading.HookConfiguratorImpl
Both the HelloHook and PlatformClassloadingHook is registerred in the hookregistry from HookConfiguratorImpl.
The HelloHook just prints out a trace message to see if we are up and running.
I have packaged this into a jar file se.nordicit.osgi.platformclassloading_1.0.0.jar which is located in the same directory as org.eclipse.osgi_3.6.2.R36x_v20110210.jar. I have also tried with an exploded structure which was then named se.nordicit.osgi.platformclassloading_1.0.0.
I run the framework with this runtime option -Dosgi.framework.extensions=se.nordicit.osgi.platformclassloading( I've tried with and without versioning and also with file: prefix ). I know that the framework is able to use runtime properties because I have also -Dosgi.console and -Dosgi.bundles which are working properly.
The adaptor hooks does not seem to be registered properly because there is no trace of the fragment bundle when doing ss in the console and no trace message is printed either.
I trying to build a bridge between a legacy system and osgi so equinox is bootstrapped and embedded into this system. We are starting an external process with equinox on the classpath lying in an library folder, it's not a "normal" eclipse application layout of the system. Everything is working just fine, it's just that I cant get this adaptor hooks thing up and running.