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 206128

Summary: EQ block in ActiveConfigAction
Product: projects Reporter: Vladimir Voskresensky <vv159170>
Component: Generic Projects UIAssignee: Jesse Glick <jglick>
Status: RESOLVED DUPLICATE    
Severity: normal CC: alexvsimon, DaHoC, GenKabuki, gorrus, jglick, PrakharMathur, stiffuser, toughschmidt, vv159170
Priority: P2 Keywords: PERFORMANCE, THREAD
Version: 7.1   
Hardware: All   
OS: All   
Issue Type: DEFECT Exception Reporter: 183560
Bug Depends on:    
Bug Blocks: 200982    
Attachments: nps snapshot
nps snapshot

Description Vladimir Voskresensky 2011-12-08 09:24:31 UTC
This bug was originally marked as duplicate of bug 205622, that is already resolved. This bug is still valid, so this seems to be another bug, but it might be related.

Build: NetBeans IDE Dev (Build 20111208-9a6d846d5dc2)
VM: Java HotSpot(TM) Server VM, 20.4-b02, Java(TM) SE Runtime Environment, 1.6.0_29-b11
OS: SunOS

User Comments:
vv159170: open ide with opened project



Maximum slowness yet reported was 16686 ms, average is 16686
Comment 1 Vladimir Voskresensky 2011-12-08 09:24:38 UTC
Created attachment 113949 [details]
nps snapshot
Comment 2 Exceptions Reporter 2011-12-26 05:58:41 UTC
Created attachment 114457 [details]
nps snapshot

just opened netbeans when it is loading two projects into the work space.
Comment 3 Vladimir Voskresensky 2012-03-14 11:57:26 UTC
Jesse, please, make presenter wait for PCP out of EDT.
Already ~30 reports of this issue

"AWT-EventQueue-1" prio=3 tid=0x0bd75400 nid=0x24 waiting for monitor entry [0x9bbff000]
   java.lang.Thread.State: BLOCKED (on object monitor)
        at org.netbeans.modules.project.ui.actions.ActiveConfigAction$ConfigMenu.findPCP(ActiveConfigAction.java:368)
        - waiting to lock <0xbaeea750> (a org.netbeans.modules.project.ui.actions.ActiveConfigAction)
        at org.netbeans.modules.project.ui.actions.ActiveConfigAction$ConfigMenu.getMenuPresenters(ActiveConfigAction.java:375)
        at org.openide.awt.DynaMenuModel.loadSubmenu(DynaMenuModel.java:108)
        at org.openide.awt.MenuBar$LazyMenu$MenuFolder.createInstance(MenuBar.java:828)
Comment 4 Jesse Glick 2012-04-12 02:57:58 UTC
Examining snapshot-566016.npss (snapshot-572382.npss seems similar), cnd.makeproject.MakeProjectConfigurationProvider.addPropertyChangeListener is taking close to ten seconds whereas it should be immediate to merely add a listener to a list. There might be other things wrong but this stands out - it is what the thread holding the monitor is waiting for. Also the reports look to involve CND projects only, which supports this hypothesis. As far as I know ACA avoids holding the monitor (uses PM.mutex) while making calls to methods that are expected to block, such as PCP.getConfigurations. From inspecting history it looks like 2f2cc8b3e4e1 might have incidentally solved this.

*** This bug has been marked as a duplicate of bug 203999 ***