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 214397 - Deadlock in org.netbeans.modules.debugger.jpda.ui.views.ViewModelListener
Summary: Deadlock in org.netbeans.modules.debugger.jpda.ui.views.ViewModelListener
Status: VERIFIED FIXED
Alias: None
Product: debugger
Classification: Unclassified
Component: Code (show other bugs)
Version: 7.2
Hardware: PC Windows 7
: P1 normal (vote)
Assignee: Martin Entlicher
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-06-18 17:53 UTC by _ gtzabari
Modified: 2012-06-28 09:17 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter:


Attachments
Thread dump (46.97 KB, text/plain)
2012-06-18 17:53 UTC, _ gtzabari
Details

Note You need to log in before you can comment on or make changes to this bug.
Description _ gtzabari 2012-06-18 17:53:35 UTC
Created attachment 121005 [details]
Thread dump

Product Version: NetBeans IDE Dev (Build 201206060001)
Java: 1.7.0_04; Java HotSpot(TM) 64-Bit Server VM 23.0-b21
System: Windows 7 version 6.1 running on amd64; Cp1252; en_CA (nb)
User directory: C:\Users\Gili\AppData\Roaming\NetBeans\dev
Cache directory: C:\Users\Gili\AppData\Local\NetBeans\Cache\dev

I ran a Maven web project. It threw an exception. I clicked on the exception in the output window and the IDE hung. I used JVisualVM to produce a thread dump which indicates a deadlock has occurred.

I believe this issue occurs randomly.
Comment 1 Martin Entlicher 2012-06-18 19:56:44 UTC
Thread "org.netbeans.modules.debugger.jpda.ui.views.ViewModelListener" creates GUI components in non-AWT thread, which is wrong.
Fixing this should resolve the deadlock.
I believe this is quite random issue.
Comment 2 Martin Entlicher 2012-06-19 14:00:49 UTC
Fixed by changeset:   224729:38d0808dbc9e
http://hg.netbeans.org/main/rev/38d0808dbc9e

Gili, can you please verify the fix after it propagates to the dev daily build, so that we can port it to 7.2? Thanks.
Comment 3 _ gtzabari 2012-06-19 14:19:56 UTC
I'll take a look. What is the best way for me to reproduce this? Last time I retried the repro steps the stack-trace wasn't hyperlinked for some reason.
Comment 4 Martin Entlicher 2012-06-19 14:58:57 UTC
I do not think this has anything to do with stack trace hyperlink.
Unfortunately, I'm not aware of reliable steps to reproduce. I though that you might know the conditions under which it occurs. It's a threading issue, which likely occurs during closing and opening the Debugging window. IMHO, either you were manually closing and opening it, or one finishing debugger session was followed by a new one starting.
Comment 5 Quality Engineering 2012-06-20 04:38:51 UTC
Integrated into 'main-golden', will be available in build *201206200001* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/38d0808dbc9e
User: mentlicher@netbeans.org
Log: #214397: Assure that the DebugTreeView is created in AWT thread.
Comment 6 Jiri Kovalsky 2012-06-20 12:48:53 UTC
Product Version: NetBeans IDE Dev (Build 201206200001)
Java: 1.7.0_04; Java HotSpot(TM) 64-Bit Server VM 23.0-b21
System: Linux version 3.0.0-12-generic running on amd64; UTF-8; cs_CZ (nb)
User directory: /home/cesilko/.netbeans/dev
Cache directory: /home/cesilko/.cache/netbeans/dev

I tried 10 times to stop and quickly start debugging session of a Maven Java SE application but no deadlock occurred. I think we can safely assume that this bug fix didn't cause any regression. Please proceed with backporting this fix to release72 branch. Thanks.
Comment 7 Martin Entlicher 2012-06-22 13:34:08 UTC
Pushed into release72 as changeset:   232091:b96047633730
http://hg.netbeans.org/releases/rev/b96047633730
Comment 8 Quality Engineering 2012-06-24 02:39:12 UTC
Integrated into 'releases', will be available in build *201206232201* or newer. Wait for official and publicly available build.
Changeset: http://hg.netbeans.org/releases/rev/b96047633730
User: mentlicher@netbeans.org
Log: #214397: Assure that the DebugTreeView is created in AWT thread.
(transplanted from 38d0808dbc9ee9580525a19efeb387c28dc3839b)
Comment 9 Jiri Kovalsky 2012-06-28 09:17:03 UTC
Product Version: NetBeans IDE 7.2 RC1 (Build 201206262201)
Java: 1.7.0_04; Java HotSpot(TM) 64-Bit Server VM 23.0-b21
System: Linux version 3.0.0-12-generic running on amd64; UTF-8; cs_CZ (nb)
User directory: /home/cesilko/.netbeans/7.2rc1
Cache directory: /home/cesilko/.cache/netbeans/7.2rc1

Verified.