Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Eclipse Communications Framework (ECF) » ClassNotFoundException
ClassNotFoundException [message #587259] Fri, 29 July 2005 13:52 Go to next message
Bryan Hunt is currently offline Bryan HuntFriend
Messages: 346
Registered: July 2009
Senior Member
> When I try to run the Create ECF container example, I get:
>
org.eclipse.ecf.core.SharedObjectCreateException:
java.lang.ClassNotFoundException:
org.eclipse.ecf.test.ui.actions.TestSharedObject
at
org.eclipse.ecf.test.TestContainer.createSharedObject(TestCo ntainer.java:266)
at

org.eclipse.ecf.test.ui.actions.CreateContainerAction.addSha redObject(CreateContainerAction.java:44)
at

org.eclipse.ecf.test.ui.actions.CreateContainerAction.run(Cr eateContainerAction.java:57)
at

org.eclipse.ui.internal.PluginAction.runWithEvent(PluginActi on.java:246)
at
org.eclipse.ui.internal.WWinPluginAction.runWithEvent(WWinPl uginAction.java:223)
at

org.eclipse.jface.action.ActionContributionItem.handleWidget Selection(ActionContributionItem.java:538)
at

org.eclipse.jface.action.ActionContributionItem.access$2(Act ionContributionItem.java:488)
at

org.eclipse.jface.action.ActionContributionItem$5.handleEven t(ActionContributionItem.java:400)
at

org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :66)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1380)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1404)
at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1389)
at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:1 237)
at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3060)
at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2712)
at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:1699)
at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1663)
at org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:367)
at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:143)
at org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplicatio n.java:103)
at
org.eclipse.core.internal.runtime.PlatformActivator$1.run(Pl atformActivator.java:226)
at

org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:376)
at
org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:163)
at

sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at
sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
at

sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
at

java.lang.reflect.Method.invoke(Method.java:324)
at org.eclipse.core.launcher.Main.invokeFramework(Main.java:334 )
at org.eclipse.core.launcher.Main.basicRun(Main.java:278)
at org.eclipse.core.launcher.Main.run(Main.java:973)
at org.eclipse.core.launcher.Main.main(Main.java:948)
Caused by: java.lang.ClassNotFoundException:
org.eclipse.ecf.test.ui.actions.TestSharedObject
at
org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:403)
at

org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:350)
at

org.eclipse.osgi.framework.adaptor.core.AbstractClassLoader. loadClass(AbstractClassLoader.java:78)
at

java.lang.ClassLoader.loadClass(ClassLoader.java:235)
at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302 )
at java.lang.Class.forName0(Native Method)
at java.lang.Class.forName(Class.java:219)
at
org.eclipse.ecf.test.TestContainer.createSharedObject(TestCo ntainer.java:252)
...

30 more
>
> Any ideas?
>
> Bryan
Re: ClassNotFoundException [message #587275 is a reply to message #587259] Fri, 29 July 2005 15:04 Go to previous messageGo to next message
Scott Lewis is currently offline Scott LewisFriend
Messages: 975
Registered: July 2009
Senior Member
Hi Bryan,

Do you have the org.eclipse.ecf.test, org.eclipse.ecf.test.provider and
org.eclipse.test.ui plugins in your runtime? It looks like you are
creating a test container. All three plugins are needed for starting
this particular container type (TestContainer).

Also...have you tried to create one of the 'generic' containers...i.e.
one with name "org.eclipse.ecf.provider.generic.Client".

LMK if you need/want more assistance. It's possible that this could be
a small bug in the test code, and if so I would like to have your
assistance identifying and fixing.

Thanks,

Scott



installedBryan Hunt wrote:
>> When I try to run the Create ECF container example, I get:
>>
> org.eclipse.ecf.core.SharedObjectCreateException:
> java.lang.ClassNotFoundException:
> org.eclipse.ecf.test.ui.actions.TestSharedObject
> at
> org.eclipse.ecf.test.TestContainer.createSharedObject(TestCo ntainer.java:266)
>
> at
> org.eclipse.ecf.test.ui.actions.CreateContainerAction.addSha redObject(CreateContainerAction.java:44)
>
> at
> org.eclipse.ecf.test.ui.actions.CreateContainerAction.run(Cr eateContainerAction.java:57)
>
> at
> org.eclipse.ui.internal.PluginAction.runWithEvent(PluginActi on.java:246)
> at
> org.eclipse.ui.internal.WWinPluginAction.runWithEvent(WWinPl uginAction.java:223)
>
> at
> org.eclipse.jface.action.ActionContributionItem.handleWidget Selection(ActionContributionItem.java:538)
>
> at
> org.eclipse.jface.action.ActionContributionItem.access$2(Act ionContributionItem.java:488)
>
> at
> org.eclipse.jface.action.ActionContributionItem$5.handleEven t(ActionContributionItem.java:400)
>
> at
> org.eclipse.swt.widgets.EventTable.sendEvent(EventTable.java :66)
> at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1380)
> at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1404)
> at org.eclipse.swt.widgets.Widget.sendEvent(Widget.java:1389)
> at org.eclipse.swt.widgets.Widget.notifyListeners(Widget.java:1 237)
> at org.eclipse.swt.widgets.Display.runDeferredEvents(Display.ja va:3060)
> at org.eclipse.swt.widgets.Display.readAndDispatch(Display.java :2712)
> at org.eclipse.ui.internal.Workbench.runEventLoop(Workbench.jav a:1699)
> at org.eclipse.ui.internal.Workbench.runUI(Workbench.java:1663)
> at
> org.eclipse.ui.internal.Workbench.createAndRunWorkbench(Work bench.java:367)
> at org.eclipse.ui.PlatformUI.createAndRunWorkbench(PlatformUI.j ava:143)
> at
> org.eclipse.ui.internal.ide.IDEApplication.run(IDEApplicatio n.java:103)
> at
> org.eclipse.core.internal.runtime.PlatformActivator$1.run(Pl atformActivator.java:226)
>
> at
> org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:376)
>
> at
> org.eclipse.core.runtime.adaptor.EclipseStarter.run(EclipseS tarter.java:163)
>
> at
> sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
> at
> sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAcce ssorImpl.java:39)
>
> at
> sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMe thodAccessorImpl.java:25)
>
> at
> java.lang.reflect.Method.invoke(Method.java:324)
> at org.eclipse.core.launcher.Main.invokeFramework(Main.java:334 )
> at org.eclipse.core.launcher.Main.basicRun(Main.java:278)
> at org.eclipse.core.launcher.Main.run(Main.java:973)
> at org.eclipse.core.launcher.Main.main(Main.java:948)
> Caused by: java.lang.ClassNotFoundException:
> org.eclipse.ecf.test.ui.actions.TestSharedObject
> at
> org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:403)
>
> at
> org.eclipse.osgi.framework.internal.core.BundleLoader.findCl ass(BundleLoader.java:350)
>
> at
> org.eclipse.osgi.framework.adaptor.core.AbstractClassLoader. loadClass(AbstractClassLoader.java:78)
>
> at
> java.lang.ClassLoader.loadClass(ClassLoader.java:235)
> at java.lang.ClassLoader.loadClassInternal(ClassLoader.java:302 )
> at java.lang.Class.forName0(Native Method)
> at java.lang.Class.forName(Class.java:219)
> at
> org.eclipse.ecf.test.TestContainer.createSharedObject(TestCo ntainer.java:252)
>
> ...
> 30 more
>
>>
>> Any ideas?
>>
>> Bryan
>
>
Re: ClassNotFoundException [message #592072 is a reply to message #587275] Sat, 07 January 2006 00:09 Go to previous messageGo to next message
Ostap Bender is currently offline Ostap BenderFriend
Messages: 17
Registered: July 2009
Junior Member
I checked the code out of cvs using the file <i> http://www.eclipse.org/ecf/org.eclipse.ecf.docs/ecf-anonymou s.psf</i>
and ran the <i>ECF Example Collab Client 1</i>. When I chose in the menu of the new running instance of Eclipse <i>Create ECF Container</i> I got the exact same error.
I looked in the newsgroup and in Bugzilla and found no conclusion to this. Strange thing is that the class not found is in the same package as the class that gets the error. Which should not happen unless there's something funny going on with classloaders. Looking in the code just before that line there is indeed some fiddling with a classloader.
Am I missing anything obvious?
Re: ClassNotFoundException [message #592077 is a reply to message #592072] Sat, 07 January 2006 06:10 Go to previous messageGo to next message
Ostap Bender is currently offline Ostap BenderFriend
Messages: 17
Registered: July 2009
Junior Member
>Strange thing is that the class not found is in the same package as the class that gets the error.

Well, I have to correct that, the two classes are obviously not in the same package. And anyway the classloader being used is the one for org.eclipse.ecf.core.ContainerFactory

Maybe posting after 1 AM was not such a good idea :)
Re: ClassNotFoundException [message #592084 is a reply to message #592077] Sat, 07 January 2006 08:22 Go to previous messageGo to next message
Ostap Bender is currently offline Ostap BenderFriend
Messages: 17
Registered: July 2009
Junior Member
Adding org.eclipse.ecf.test.ui to the Require-Bundle of MANIFEST.MF in
org.eclipse.ecf.test fixed the problem
Re: ClassNotFoundException [message #592092 is a reply to message #592084] Sat, 07 January 2006 19:54 Go to previous message
Scott Lewis is currently offline Scott LewisFriend
Messages: 975
Registered: July 2009
Senior Member
Hi Ostap,

I added this dependency to org.eclipse.ecf.test and checked it in.
Thanks for the report.

One thing...I need to apologize because with the 0.6.0 work I've been
moving over the ECF codebase to use the Eclipse 3.1/OSGI 'buddy loader'
mechanisms for classloading on deserialization, and so the classloading
stuff is going to be quite different (and better/more manageable).

Thanks,

Scott


Ostap Bender wrote:
> Adding org.eclipse.ecf.test.ui to the Require-Bundle of MANIFEST.MF in
> org.eclipse.ecf.test fixed the problem
Previous Topic:Is ECF suited for distributed process administration?
Next Topic:Build Script
Goto Forum:
  


Current Time: Wed Dec 17 23:13:54 GMT 2014

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

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