Skip to main content

Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Use same Package/Class in System Classloader and Bundle Classloader(Getting the same class instance in all bundles)
Use same Package/Class in System Classloader and Bundle Classloader [message #1725792] Mon, 07 March 2016 16:54
Bill Mair is currently offline Bill MairFriend
Messages: 72
Registered: July 2009
I'm using a custom logging Formatter (let say it is and because I need it before the FrameWork is completely loaded, we have added this to the Xbootclasspath.

The class is provided by the bundle "", which is appended above as well as being defined in the config.ini.

The Formatter class has a ThreadLocal instance that allows me to track calls across the various layers but the ThreadLocal instance is different, as is the class, in the logger from the instances in the bundles are using to set the identifier.

So the main problem is that I have the same thread but different instances of the same class. How do I get/force the bundles to use the instance that was loaded from the Xbootclasspath ?

I have tried:;version="1.2.3";version="0.0.0";version="1.2.3"

And nothing seems to change the value of "org.osgi.framework.system.packages" shown in "props".

Am I trying to do something that simply can't be done? Or is there a "special" option in equinox that is required before "org.osgi.framework.system.packages.extra" is used?
Previous Topic:What is a SSCCE using EclipseStarter to launch Equinox with a
Next Topic:What JRE is considered the "Perfect Match" for OSGi 1.2
Goto Forum:

Current Time: Mon Oct 03 22:26:07 GMT 2022

Powered by FUDForum. Page generated in 0.01729 seconds
.:: Contact :: Home ::.

Powered by: FUDforum 3.0.2.
Copyright ©2001-2010 FUDforum Bulletin Board Software

Back to the top