Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Equinox » Classloading problem
Classloading problem [message #131970] Thu, 28 May 2009 16:39 Go to next message
Eclipse UserFriend
Originally posted by: Daniel.Mazurek.NightLabs.de

Hello,

I have the following problem:
I'm using a BIRT runtime in an JBossAS. Inside this JBossAS we have
Mozilla Rhino (v1.7) deployed and need it in this special version.
Inside the Birt runtime there is also a Mozilla Rhino (v1.6) contained.

Because some classes which are deployed in the JBossAS are needed by our
reporting implementation we use the osgi.parentClassloader=fwk option,
so that the (BIRT-)OSGI runtime can load our (deployed) classes.
The problem now is that it loads the Rhino (1.7) classes from the
JBossAS deploy, instead of the (1.6) classes delivered with the BIRT
runtime which lead to errors inside BIRT.

Actually reading the documentation I thought that OSGI would delegate to
the parent classlaoder at last after not having found the classes inside
its (BIRT) bundles.
So now I'm wondering why OSGI doesn't find the Mozilla Rhino classes
form the org.motilla.rhino bundle inside the delivered BIRT deployment.

My question is now if there exists an option in OSGI to exclude classes
to be loaded from the framework classloader, similiar to
org.osgi.framework.bootdelegations but the other way round (exclude
instead of include), so that these classes would be tried to be loaded
first by the BundleClassLoader instead of the framework classloader.

Or if somebody has another idea how to solve this problems,
help is very much appreciated.

Best regards
Daniel
interface not visible from the class loader (using eclipse buddy policy) [message #132086 is a reply to message #131970] Fri, 29 May 2009 14:17 Go to previous message
Shailendra is currently offline ShailendraFriend
Messages: 3
Registered: July 2009
Junior Member
Hi All,

I have an Eclipse RCP application based on eclipse 3.5. I want to connect to an open EJB server. I have created one OSGi bundle(com.test.geronimo) for
openejb-client-3.1.1-SNAPSHOT.jar and geronimo-ejb_3.0_spec-1.0.1.jar.

I have also created a declarative service(com.test.ds) that actually does the work of connecting to the EJB server and then lookup of desired EJB
instance.

While trying to lookup the ejb with the conventional method(below) :

Properties props = new Properties();
props.put("java.naming.factory.initial","org.apache.openejb.client.RemoteInitialContextFactory ");
props.put("java.naming.provider.url", "127.0.0.1:4201");
ejbInitialContext = new InitialContext(props);
orderEntryBean = (OrderEntryRemote) ejbInitialContext.lookup("OrderEntryBeanRemote");

got the exception of class not found of OrderEntryRemote class.
Doing some search on web I found something class eclipe buddy policy. Using it i have made com.test.geronimo and com.test.ds buddies.

After that i am getting an error of
interface org.apache.openejb.client.EJBObjectProxy is not visible from class loader
which is there in the same bundle com.test.geronimo.

I have already exported the packages from com.test.geronimo and imported the required ones to the com.test.ds.

Can someone give me any pointer from here
Previous Topic:Disabling Uninstall?
Next Topic:Can p2 touchpoint actions be conditional? (Sun JVM vs. Apple JVM)
Goto Forum:
  


Current Time: Thu Apr 25 23:52:14 GMT 2024

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

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

Back to the top