This Bugzilla instance is a read-only archive of historic NetBeans bug reports. To report a bug in NetBeans please follow the project's instructions for reporting issues.

Bug 213404

Summary: ClassNotFoundException: org.openide.util.actions.ActionInvoker
Product: platform Reporter: Exceptions Reporter <exceptions_reporter>
Component: Module SystemAssignee: Jaroslav Tulach <jtulach>
Status: RESOLVED WORKSFORME    
Severity: normal CC: mgoe
Priority: P1    
Version: 7.2   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter: 188827
Attachments: stacktrace
Extensions added to a jdk7u4 64bit Linux

Description Exceptions Reporter 2012-06-01 15:49:43 UTC
This issue was reported manually by mgoe.
It already has 1 duplicates 


Build: NetBeans IDE 7.2 Beta (Build 201205031832)
VM: Java HotSpot(TM) 64-Bit Server VM, 23.0-b21, Java(TM) SE Runtime Environment, 1.7.0_04-b20
OS: Linux

User Comments:
GUEST: Trying to open java source file after clean build of module suite project.




Stacktrace: 
java.lang.ClassNotFoundException: org.openide.util.actions.ActionInvoker
   at java.net.URLClassLoader$1.run(URLClassLoader.java:366)
   at java.net.URLClassLoader$1.run(URLClassLoader.java:355)
   at java.security.AccessController.doPrivileged(AccessController.java:0)
   at java.net.URLClassLoader.findClass(URLClassLoader.java:354)
   at java.lang.ClassLoader.loadClass(ClassLoader.java:423)
   at sun.misc.Launcher$AppClassLoader.loadClass(Launcher.java:308)
Comment 1 Exceptions Reporter 2012-06-01 15:49:48 UTC
Created attachment 120218 [details]
stacktrace
Comment 2 Jaroslav Tulach 2012-06-01 16:03:15 UTC
Repeatable? If so, we can investigate more. If that happened only once, I am afraid we won't find the cause.

I see a lot of JARs in endorsed directories including Xalan. It might be the cause of the failures. Try to run on pristine JDK.
Comment 3 mgoe 2012-06-04 08:33:05 UTC
Hello Jaroslav,

you are right we have some jars installed using the endorsed mechanism. We do this because we have several Java applications (one based on the Netbeans platform, the others are "normal" Java applications). This way we can make sure that each application uses the same version of XML-tools, CORBA and so on. We are using the endorsed mechanism for many years now (since jdk5 and Netbeans 5) and we never had trouble so far.

The problem may be related to the endorsed mechanism, but if you search for ClassNotFoundExceptions and NoClassDefFoundErrors in the Netbeans exception reports you will find hundreds of reports (e.g. http://statistics.netbeans.org/analytics/detail.do?id=186151, http://statistics.netbeans.org/analytics/detail.do?id=166549) and I doubt that all these reporters are using the endorsed mechanism.

It is also curious that our own applications don't suffer from these ClassNotFoundExceptions and NoClassDefFoundErrors (see bug #213396). Even the application based on the Netbeans platform is not affected. I don't have an explanation for that.

In order to help you to analyze the problem I could send you a tar file (approx. 85 MB) of the JDK we are using, so that you could try it yourself on a 64bit Linux system. We tried several different Linux distributions (openSUSE 11.4/12.1, CentOS 5.8/6.2, Ubuntu 12.04LTS) and all behave the same.

Best regards,
Martin
Comment 4 Jaroslav Tulach 2012-06-04 09:36:39 UTC
Btw. if this bug reproduced in the same environment as bug 213396? If so, consider closing one of them as duplicate.
Comment 5 mgoe 2012-06-04 09:52:50 UTC
Yes, its the same environment. I'm currently preparing a tar file with just our extensions of the JDK.
Comment 6 mgoe 2012-06-04 10:00:57 UTC
Created attachment 120299 [details]
Extensions added to a jdk7u4 64bit Linux

To install the extensions please perform the following steps:

cd <JDK_INSTALL_DIR>
tar xvzf jdk_extensions.tgz
Comment 7 Jaroslav Tulach 2012-06-07 09:22:04 UTC
I have just jdk7u4@32bits, but after installing your extensions I can't reproduce the problem.

I am not sure how to debug who is destroying your application classpath. Only when f6bfdaee6030 gets in (#213396), there should be some warning in log. 

You could find this out by using debugger yourself. The starting point is sun.misc.Launcher, with its inner class AppClassLoader and the ucp field. Maybe some malicious code modifies this field via reflection.