Set thread contextClassLoader to the one from the bundle when activating a bundle
See https://github.com/killbill/killbill-platform/issues/5.
Unfortunately this is not solvable because we don't have the class loader available before we start the bundle (and enter the Felix machine), and when we hit the start method from the activator, this is too late-- we are already in the plugin.
Looks like the solution is to set that context class loader in the plugin itself but that requires to be done in each plugin (or at least the subset that need it for their start sequence to happen correctly).
There is a SO thread on that topic (http://stackoverflow.com/questions/2198928/better-handling-of-thread-context-classloader-in-osgi)
Looks like the solution is to set that context class loader in the plugin itself but that requires to be done in each plugin (or at least the subset that need it for their start sequence to happen correctly).
For reference, the only plugin that requires it today is Forte.