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.
I was trying to clean up some things. I went to my "Find usages" output window to click on an import I was going to remove. Pressed CTRL-E to delete the line. My machine was busy swapping things and was not very responsive. To reduce memory comsumption I closed my swing app that I had started through the IDE. My line never got deleted and the UI is completely unresponsive. Some output from JConsole is attached
Created attachment 61782 [details] JConsole thread info
Please attach a full thread dump. BreakpointAnnotationProvider.java:182 is waiting on breakpointToAnnotations lock, but it's not apparent who owns it and why it's not released.
I scanned through all the threads and didn't notice anything suspicious or relevant, except what I sent you. Clearly, though, I could have missed something. Hopefully knowing where it locked up can at least give you guys enough to ensure that the state variables around the condition are being used correctly. If it happens again I will get more. I don't know how to get the full thread dump from netbeans. I used JConsole to get what I got...and that was by selecting each thread and then copy/pasting the result. I do not know a way to get JConsole to dump all the threads to a file. The rest of the info from that lock up is already lost in the sands of time. Can you tell me a way to get a full thread dump, besides just going in jconsole and selecting on every thread and copying the result?
This time I was exiting the project properties dialog. I edited one of my own ant files that I use for packaging, but didn't click "Save". I tried to open the project properties dialog and NB prompted me to save my ant file first. I said YES (or whatever) and the dialog opened. I added a directory to my compile / excludes path. I clicked OK and the dialog went away. After that I was hosed. I tried to do open a file from the project window, but to no avail.
Created attachment 62488 [details] NB log file
Created attachment 62489 [details] JConsole thread and vm info
BTW, a customization I made to my installation was to apply the patch for 128326 (from May 20, attached by jlahoda) I have used by debugger today, but was not running or debugging anything at the time of the lockup.
One last comment. I now see that somehow when I was editing my ant file, somewhere an extra character got stuck into a line, which caused syntax error in the file. It was not where I was editing, but I must assume that I somehow I accidentally put it there. I did notice this error in the project tree (with the little error icon) after I closed the project dialog. I thought this was just an out-of-date parser problem, since I was confident my edit (deleting some lines) was a clean edit. However, now that I re-opened NB, I can see that somehow a spurious 'l' character got put in one of my commands. ---------- I hope something I said or put in the attachments helps somehow!
This has no happened to me again. This time I was just adding some excludes to my project. I clicked OK, the OK button is depressed but the Project Properties dialog is not closing. No CPU activity, no nothing. I have been a big NB support in the past, but this is really starting to get frustrating. (I don't generally use swear words when I write or speak, but I feel I may start soon.) You have a missed signal or something here! Name: AWT-EventQueue-1 State: WAITING on org.openide.util.Mutex$QueueCell@17b3b69 Total blocked: 33,872 Total waited: 80,171 Stack trace: java.lang.Object.wait(Native Method) java.lang.Object.wait(Object.java:485) org.openide.util.Mutex$QueueCell.sleep(Mutex.java:1601) org.openide.util.Mutex.enterImpl(Mutex.java:723) org.openide.util.Mutex.enter(Mutex.java:630) org.openide.util.Mutex.readEnter(Mutex.java:613) org.openide.util.Mutex.readAccess(Mutex.java:359) org.openide.explorer.view.VisualizerNode$QP.run(VisualizerNode.java:669) org.openide.util.Mutex.doEvent(Mutex.java:1335) org.openide.util.Mutex.writeAccess(Mutex.java:452) org.openide.explorer.view.VisualizerNode$QP.runSafe(VisualizerNode.java:642) org.openide.explorer.view.VisualizerNode.propertyChange(VisualizerNode.java:418) sun.reflect.GeneratedMethodAccessor11.invoke(Unknown Source) sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) java.lang.reflect.Method.invoke(Method.java:597) org.openide.util.WeakListenerImpl$ProxyListener.invoke(WeakListenerImpl.java:449) $Proxy6.propertyChange(Unknown Source) org.openide.nodes.Node.fireOwnPropertyChange(Node.java:1145) org.openide.nodes.FilterNode$NodeAdapter.propertyChange(FilterNode.java:1179) org.openide.nodes.FilterNode$NodeAdapter.propertyChange(FilterNode.java:1154) org.openide.nodes.Node.fireOwnPropertyChange(Node.java:1145) org.openide.nodes.FilterNode$NodeAdapter.propertyChange(FilterNode.java:1179) org.openide.nodes.FilterNode$NodeAdapter.propertyChange(FilterNode.java:1154) org.openide.nodes.Node.fireOwnPropertyChange(Node.java:1145) org.openide.nodes.FilterNode$NodeAdapter.propertyChange(FilterNode.java:1179) org.openide.nodes.FilterNode$NodeAdapter.propertyChange(FilterNode.java:1154) org.openide.nodes.Node.fireOwnPropertyChange(Node.java:1145) org.openide.nodes.Node.fireNameChange(Node.java:983) org.netbeans.spi.java.project.support.ui.TreeRootNode.propertyChange(TreeRootNode.java:145) org.openide.util.WeakListenerImpl$PropertyChange.propertyChange(WeakListenerImpl.java:186) java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:339) java.beans.PropertyChangeSupport.firePropertyChange(PropertyChangeSupport.java:276) org.netbeans.spi.project.support.ant.SourcesHelper$SourceRoot$Group.propertyChange(SourcesHelper.java:224) org.openide.util.WeakListenerImpl$PropertyChange.propertyChange(WeakListenerImpl.java:186) org.netbeans.spi.project.support.ant.PropertyUtils$SequentialPropertyEvaluator.stateChanged(PropertyUtils.java:874) org.openide.util.WeakListenerImpl$Change.stateChanged(WeakListenerImpl.java:319) org.openide.util.ChangeSupport.fireChange(ChangeSupport.java:123) org.openide.util.ChangeSupport.fireChange(ChangeSupport.java:109) org.netbeans.spi.project.support.ant.ProjectProperties$PP$2.run(ProjectProperties.java:332) org.netbeans.spi.project.support.ant.ProjectProperties$PP$2.run(ProjectProperties.java:331) org.openide.util.Mutex.readAccess(Mutex.java:327) org.openide.util.Mutex$1R.run(Mutex.java:1299) org.openide.util.Mutex.doWrapperAccess(Mutex.java:1318) org.openide.util.Mutex.readAccess(Mutex.java:275) org.netbeans.spi.project.support.ant.ProjectProperties$PP.fireChange(ProjectProperties.java:338) org.netbeans.spi.project.support.ant.ProjectProperties$PP.put(ProjectProperties.java:210) org.netbeans.spi.project.support.ant.ProjectProperties.putProperties(ProjectProperties.java:123) org.netbeans.spi.project.support.ant.AntProjectHelper$8.run(AntProjectHelper.java:677) org.netbeans.spi.project.support.ant.AntProjectHelper$8.run(AntProjectHelper.java:676) org.openide.util.Mutex.writeAccess(Mutex.java:433) org.openide.util.Mutex$1R.run(Mutex.java:1305) org.openide.util.Mutex.doWrapperAccess(Mutex.java:1318) org.openide.util.Mutex.writeAccess(Mutex.java:384) org.netbeans.spi.project.support.ant.AntProjectHelper.putProperties(AntProjectHelper.java:675) org.netbeans.modules.java.api.common.ant.UpdateHelper$2.run(UpdateHelper.java:114) org.openide.util.Mutex.writeAccess(Mutex.java:469) org.openide.util.Mutex$1R.run(Mutex.java:1307) org.openide.util.Mutex.doWrapperAccess(Mutex.java:1318) org.openide.util.Mutex.writeAccess(Mutex.java:458) org.netbeans.modules.java.api.common.ant.UpdateHelper.putProperties(UpdateHelper.java:109) org.netbeans.modules.java.j2seproject.ui.customizer.J2SEProjectProperties.storeProperties(J2SEProjectProperties.java:515) org.netbeans.modules.java.j2seproject.ui.customizer.J2SEProjectProperties.access$300(J2SEProjectProperties.java:98) org.netbeans.modules.java.j2seproject.ui.customizer.J2SEProjectProperties$1.run(J2SEProjectProperties.java:411) org.netbeans.modules.java.j2seproject.ui.customizer.J2SEProjectProperties$1.run(J2SEProjectProperties.java:396) org.openide.util.Mutex.writeAccess(Mutex.java:433) org.openide.util.Mutex$1R.run(Mutex.java:1305) org.openide.util.Mutex.doWrapperAccess(Mutex.java:1318) org.openide.util.Mutex.writeAccess(Mutex.java:426) org.netbeans.modules.java.j2seproject.ui.customizer.J2SEProjectProperties.save(J2SEProjectProperties.java:394) org.netbeans.modules.java.j2seproject.ui.customizer.CustomizerProviderImpl$OptionListener.actionPerformed(CustomizerProviderImpl.java:158) org.netbeans.modules.project.uiapi.CustomizerDialog$OptionListener$1.run(CustomizerDialog.java:213) org.openide.util.Mutex.writeAccess(Mutex.java:433) org.openide.util.Mutex$1R.run(Mutex.java:1305) org.netbeans.api.project.ProjectManager$2$1.run(ProjectManager.java:120) org.openide.filesystems.EventControl.runAtomicAction(EventControl.java:120) org.openide.filesystems.FileSystem.runAtomicAction(FileSystem.java:499) org.openide.filesystems.FileUtil.runAtomicAction(FileUtil.java:215) org.netbeans.api.project.ProjectManager$2.execute(ProjectManager.java:118) org.openide.util.Mutex.doWrapperAccess(Mutex.java:1320) org.openide.util.Mutex.writeAccess(Mutex.java:384) org.netbeans.modules.project.uiapi.CustomizerDialog$OptionListener.actionPerformed(CustomizerDialog.java:211) javax.swing.AbstractButton.fireActionPerformed(AbstractButton.java:1995) javax.swing.AbstractButton$Handler.actionPerformed(AbstractButton.java:2318) javax.swing.DefaultButtonModel.fireActionPerformed(DefaultButtonModel.java:387) javax.swing.DefaultButtonModel.setPressed(DefaultButtonModel.java:242) javax.swing.plaf.basic.BasicButtonListener.mouseReleased(BasicButtonListener.java:236) java.awt.Component.processMouseEvent(Component.java:6041) javax.swing.JComponent.processMouseEvent(JComponent.java:3265) java.awt.Component.processEvent(Component.java:5806) java.awt.Container.processEvent(Container.java:2058) java.awt.Component.dispatchEventImpl(Component.java:4413) java.awt.Container.dispatchEventImpl(Container.java:2116) java.awt.Component.dispatchEvent(Component.java:4243) java.awt.LightweightDispatcher.retargetMouseEvent(Container.java:4322) java.awt.LightweightDispatcher.processMouseEvent(Container.java:3986) java.awt.LightweightDispatcher.dispatchEvent(Container.java:3916) java.awt.Container.dispatchEventImpl(Container.java:2102) java.awt.Window.dispatchEventImpl(Window.java:2440) java.awt.Component.dispatchEvent(Component.java:4243) java.awt.EventQueue.dispatchEvent(EventQueue.java:599) org.netbeans.core.TimableEventQueue.dispatchEvent(TimableEventQueue.java:104) java.awt.EventDispatchThread.pumpOneEventForFilters(EventDispatchThread.java:273) java.awt.EventDispatchThread.pumpEventsForFilter(EventDispatchThread.java:183) java.awt.EventDispatchThread.pumpEventsForHierarchy(EventDispatchThread.java:173) java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:168) java.awt.EventDispatchThread.pumpEvents(EventDispatchThread.java:160) java.awt.EventDispatchThread.run(EventDispatchThread.java:121) Name: pool-1-thread-1 State: WAITING on java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject@fb38fb Total blocked: 0 Total waited: 1,059 Stack trace: sun.misc.Unsafe.park(Native Method) java.util.concurrent.locks.LockSupport.park(LockSupport.java:158) java.util.concurrent.locks.AbstractQueuedSynchronizer$ConditionObject.await(AbstractQueuedSynchronizer.java:1925) java.util.concurrent.LinkedBlockingQueue.take(LinkedBlockingQueue.java:358) java.util.concurrent.ThreadPoolExecutor.getTask(ThreadPoolExecutor.java:946) java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:906) java.lang.Thread.run(Thread.java:619) Name: Java Source Worker Thread State: WAITING on org.openide.util.Mutex$QueueCell@1b3f874 Total blocked: 1,155 Total waited: 4,134 Stack trace: java.lang.Object.wait(Native Method) java.lang.Object.wait(Object.java:485) org.openide.util.Mutex$QueueCell.sleep(Mutex.java:1601) org.openide.util.Mutex.enterImpl(Mutex.java:723) org.openide.util.Mutex.enter(Mutex.java:630) org.openide.util.Mutex.readEnter(Mutex.java:613) org.openide.util.Mutex.readAccess(Mutex.java:324) org.openide.util.Mutex$1R.run(Mutex.java:1299) org.netbeans.api.project.ProjectManager$2$1.run(ProjectManager.java:120) org.openide.filesystems.EventControl.runAtomicAction(EventControl.java:120) org.openide.filesystems.FileSystem.runAtomicAction(FileSystem.java:499) org.openide.filesystems.FileUtil.runAtomicAction(FileUtil.java:215) org.netbeans.api.project.ProjectManager$2.execute(ProjectManager.java:118) org.openide.util.Mutex.doWrapperAccess(Mutex.java:1320) org.openide.util.Mutex.readAccess(Mutex.java:320) org.netbeans.api.project.ProjectManager.findProject(ProjectManager.java:241) org.netbeans.modules.projectapi.SimpleFileOwnerQueryImplementation.getOwner(SimpleFileOwnerQueryImplementation.java:121) org.netbeans.api.project.FileOwnerQuery.getOwner(FileOwnerQuery.java:101) org.netbeans.modules.java.project.ProjectClassPathProvider.findClassPath(ProjectClassPathProvider.java:60) org.netbeans.api.java.classpath.ClassPath.getClassPath(ClassPath.java:538) org.netbeans.modules.java.source.usages.RepositoryUpdater$CompileWorker.updateFolder(RepositoryUpdater.java:2056) org.netbeans.modules.java.source.usages.RepositoryUpdater$CompileWorker.access$800(RepositoryUpdater.java:1230) org.netbeans.modules.java.source.usages.RepositoryUpdater$CompileWorker$1.run(RepositoryUpdater.java:1303) org.netbeans.modules.java.source.usages.RepositoryUpdater$CompileWorker$1.run(RepositoryUpdater.java:1272) org.netbeans.modules.java.source.usages.ClassIndexManager.writeLock(ClassIndexManager.java:105) org.netbeans.modules.java.source.usages.RepositoryUpdater$CompileWorker.run(RepositoryUpdater.java:1269) org.netbeans.modules.java.source.usages.RepositoryUpdater$CompileWorker.run(RepositoryUpdater.java:1230) org.netbeans.api.java.source.JavaSource$CompilationJob.run(JavaSource.java:1550) java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:441) java.util.concurrent.FutureTask$Sync.innerRun(FutureTask.java:303) java.util.concurrent.FutureTask.run(FutureTask.java:138) java.util.concurrent.ThreadPoolExecutor$Worker.runTask(ThreadPoolExecutor.java:885) java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:907) java.lang.Thread.run(Thread.java:619)
The synchronized section in BreakpointAnnotationProvider.propertyChange() has been recently changed in trunk. Now, the execution of this part is postponed and done in RequestProcessor. This should fix the given problem. The second case is different, there is "Java Source Worker Thread" involved and some Mutex race condition. Reassigning to java module for further evaluation.
The thread dump is not complete, but seems as a deadlock among: Project.mutex,Children.mutex,Javac.lock. 1)First Thread holds: project.mutex acquires: children.mutex 2)Second Thread holds: javac.lock acquires: project.mutex 3)Missing thread has to hold Children.mutex acquires: javac.lock
The second deadlock is a duplicate of the fixed issue #133639. The fix is also available in NB 6.1 patch set 2 (61fixes2-fixed). *** This issue has been marked as a duplicate of 133639 ***