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.
Build: NetBeans IDE Dev (Build 090803) VM: Java HotSpot(TM) Client VM, 1.5.0_06-b05, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_06-b05 OS: Windows XP, 5.1, x86 User Comments: tboudreau: Deleting a class in a module I am about to add to nbsrc, marked as new in hg tboudreau: Open dialog after startup Stacktrace: java.security.AccessControlException: access denied (java.lang.RuntimePermission modifyThread) at java.security.AccessControlContext.checkPermission(AccessControlContext.java:264) at java.security.AccessController.checkPermission(AccessController.java:427) at java.util.concurrent.ThreadPoolExecutor.shutdown(ThreadPoolExecutor.java:893) at java.util.concurrent.ScheduledThreadPoolExecutor.shutdown(ScheduledThreadPoolExecutor.java:455) at java.util.concurrent.Executors$DelegatedExecutorService.shutdown(Executors.java:594) at org.netbeans.modules.profiler.actions.SelfSamplerAction$Controller.actionPerformed(SelfSamplerAction.java:193)
Created attachment 85738 [details] stacktrace
This issue already has 5 duplicates see http://statistics.netbeans.org/exceptions/detail.do?id=152576
Build: NetBeans IDE Dev (Build 200908022240) VM: Java HotSpot(TM) Client VM, 1.5.0_06-b05, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_06-b05 OS: Windows NT (unknown), 6.0, x86 User Comments: Stacktrace: java.security.AccessControlException: access denied (java.lang.RuntimePermission modifyThread) at java.security.AccessControlContext.checkPermission(AccessControlContext.java:264) at java.security.AccessController.checkPermission(AccessController.java:427) at java.util.concurrent.ThreadPoolExecutor.shutdown(ThreadPoolExecutor.java:893) at java.util.concurrent.ScheduledThreadPoolExecutor.shutdown(ScheduledThreadPoolExecutor.java:455) at java.util.concurrent.Executors$DelegatedExecutorService.shutdown(Executors.java:594) at org.netbeans.modules.profiler.actions.SelfSamplerAction$Controller.actionPerformed(SelfSamplerAction.java:193)
Created attachment 86487 [details] stacktrace
This issue already has 6 duplicates see http://statistics.netbeans.org/exceptions/detail.do?id=152576
*** Issue 170791 has been marked as a duplicate of this issue. ***
Use JDK 1.6 as workaround.
Not really a useful workaround, as I need $NB_SRC/nbbuild/user.build.properties to point to JDK 5, which means the run target of any module under $NB_SRC will be run on JDK 5 - as it should be (I will need to test on JDK 5 before committing anything, so running on JDK 6 just wastes time). FYI, this appears to happen on any dialog being opened and also when any dialog receives a mouse event. Very annoying, esp. in the case of modal dialogs where the exception dialog gets parented to the modal dialog.
AccessControlException is caused by the bug #6385134 in JDK. This bug is fixed in JDK 6.
Case from issue 170791 (taking snapshot with Profile-Me action) is working file in NB 6.7.1. It starts failing after integration of issue #168547. Due to JDK bug #6385134 the ThreadPoolExecutor shutdown method makes direct calls to AccessController.checkPermission. Case from issue 170791 was working fine before integration of issue #168547 since all methods on the call stack was from JDK or from regular netbeans modules, which protection domain has all permissions. However issue #168547 introduced methods from org.netbeans.modules.openide.util.ActionsBridge which are from org-openide-util.jar module. org-openide-util is loaded by system classloader, which does not have modifyThread RuntimePermission and therefore call to ThreadPoolExecutor.shutdown fails on JDK 5. According to other stack traces from exception reporter, there are other places, where the same situation can happen, but all includes classes from org-openide-util.jar on the stack trace.
Fixed in profiler-main changeset: 142872:bf68fa7872d8 user: Tomas Hurka <thurka@netbeans.org> date: Mon Aug 31 18:01:31 2009 +0200 summary: bugfix #169770, use java.util.Timer to do the sampling; redo synchornization in StackTraceSnapshotBuilder so that createSnapshot() can be safely invoked from non-sampling thread
Build: NetBeans IDE Dev (Build 090831) VM: Java HotSpot(TM) Client VM, 1.5.0_16-b02, Java(TM) 2 Runtime Environment, Standard Edition, 1.5.0_16-b02 OS: Linux, 2.6.24-24-generic, i386 User Comments: Stacktrace: java.security.AccessControlException: access denied (java.lang.RuntimePermission modifyThread) at java.security.AccessControlContext.checkPermission(AccessControlContext.java:264) at java.security.AccessController.checkPermission(AccessController.java:427) at java.util.concurrent.ThreadPoolExecutor.shutdown(ThreadPoolExecutor.java:893) at java.util.concurrent.ScheduledThreadPoolExecutor.shutdown(ScheduledThreadPoolExecutor.java:455) at java.util.concurrent.Executors$DelegatedExecutorService.shutdown(Executors.java:594) at org.netbeans.modules.profiler.actions.SelfSamplerAction$Controller.actionPerformed(SelfSamplerAction.java:249)
Created attachment 86919 [details] stacktrace
Integrated into 'main-golden', will be available in build *200909021401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress) Changeset: http://hg.netbeans.org/main-golden/rev/bf68fa7872d8 User: Tomas Hurka <thurka@netbeans.org> Log: bugfix #169770, use java.util.Timer to do the sampling; redo synchornization in StackTraceSnapshotBuilder so that createSnapshot() can be safely invoked from non-sampling thread