Skip to main content


Eclipse Community Forums
Forum Search:

Search      Help    Register    Login    Home
Home » Eclipse Projects » Rich Client Platform (RCP) » Exceptions at startup of application
Exceptions at startup of application [message #444099] Thu, 09 February 2006 15:55 Go to next message
Eclipse UserFriend
Originally posted by: hakan222.gmail.com

Hello,

When running my application in debugmode i noticed that a lot of
exceptions are thrown. In this case I have added ClassNotFoundException
as breakpoint and launch my RCP. Before my application is launched I get
this exception:

Thread [main] (Suspended (exception ClassNotFoundException))
ClassLoader.findBootstrapClass(String) line: not available [native method]
Launcher$ExtClassLoader(ClassLoader).findBootstrapClass0(Str ing) line: 891
Launcher$ExtClassLoader(ClassLoader).loadClass(String, boolean) line: 301
Launcher$AppClassLoader(ClassLoader).loadClass(String, boolean) line: 299
Launcher$AppClassLoader.loadClass(String, boolean) line: 268
Launcher$AppClassLoader(ClassLoader).loadClass(String) line: 251
Launcher$AppClassLoader(ClassLoader).loadClassInternal(Strin g) line: 319

The string it is looking for is: org.eclipse.core.launcher.Main

When I resume the next exception is:

Thread [main] (Suspended (exception ClassNotFoundException))
URLClassLoader$1.run() line: 200 [local variables unavailable]
AccessController.doPrivileged(PrivilegedExceptionAction<T>,
AccessControlContext) line: not available [native method]
Launcher$ExtClassLoader(URLClassLoader).findClass(String) line: 188
Launcher$ExtClassLoader(ClassLoader).loadClass(String, boolean) line: 306
Launcher$AppClassLoader(ClassLoader).loadClass(String, boolean) line: 299
Launcher$AppClassLoader.loadClass(String, boolean) line: 268
Launcher$AppClassLoader(ClassLoader).loadClass(String) line: 251
Launcher$AppClassLoader(ClassLoader).loadClassInternal(Strin g) line: 319

And this goes on for quite a while when resuming.

So the question is how I can avoid all this exceptions? Even when I run
the "Hello RCP" application I get them.

Thanks in advance

Håkan
Re: Exceptions at startup of application [message #444102 is a reply to message #444099] Thu, 09 February 2006 17:29 Go to previous messageGo to next message
Paul Webster is currently offline Paul WebsterFriend
Messages: 6859
Registered: July 2009
Location: Ottawa
Senior Member

While I'm not sure, I think you really don't want to break on
ClassNotFoundException until your system is up in a stable state ... the
first time every class is referenced, you get a CNFE and then the JVM
loads the class ... that means A LOT of exceptions.

Better to set a breakpoint at a known state, and the activate the CNFE
breakpoint.

Later,
PW


Re: Exceptions at startup of application [message #444107 is a reply to message #444102] Thu, 09 February 2006 18:57 Go to previous message
Eclipse UserFriend
Originally posted by: hakan222.gmail.com

Paul Webster wrote:
> While I'm not sure, I think you really don't want to break on
> ClassNotFoundException until your system is up in a stable state ... the
> first time every class is referenced, you get a CNFE and then the JVM
> loads the class ... that means A LOT of exceptions.
>
> Better to set a breakpoint at a known state, and the activate the CNFE
> breakpoint.
>
> Later,
> PW

Thanks Paul,

I didn't know that you got a CNFE the first time every class is loaded.
Made a quick simple java program and it behaved the same way. You learn
something new every day ;)

/ Håkan
Previous Topic:Export product
Next Topic:Thread problem
Goto Forum:
  


Current Time: Tue Nov 12 00:10:07 GMT 2024

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

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

Back to the top