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 173312

Summary: 34s in WatchPanel setupContext
Product: debugger Reporter: Jaroslav Tulach <jtulach>
Component: JavaAssignee: Martin Entlicher <mentlicher>
Status: VERIFIED FIXED    
Severity: blocker CC: mslama
Priority: P3 Keywords: PERFORMANCE
Version: 6.x   
Hardware: All   
OS: All   
URL: http://statistics.netbeans.org/exceptions/detail.do?id=159254
Issue Type: DEFECT Exception Reporter: 159254
Attachments: nps snapshot

Description Jaroslav Tulach 2009-09-29 19:44:50 UTC
Build: NetBeans IDE Dev (Build 090914)
VM: Java HotSpot(TM) Client VM, 14.1-b02, Java(TM) SE Runtime Environment, 1.6.0_15-b03
OS: Linux, 2.6.29.6-desktop-1mnb, i386
Maximum slowness yet reported was 34892 ms, average is 34892
Comment 1 Jaroslav Tulach 2009-09-29 19:45:00 UTC
Created attachment 88546 [details]
nps snapshot
Comment 2 David Strupl 2009-10-01 09:08:16 UTC
The problem is that SourceLevelQueryImpl.getSourceLevel took 32 seconds in thread "openide.text document processing". It
was blocked by the computation of apisupport in thread "Java Node Badge processor" which was most probably triggered by
the Hg refresh. Assigning to apisupport to evaluate.
Comment 3 mslama 2009-10-01 09:38:55 UTC
Problem is that debugger calls openDocument in AWT thread. It should be done from another thread as this call is
blocking and can take long time.
Comment 4 Jaroslav Tulach 2009-10-01 09:40:20 UTC
This is problem of the caller to openDocument. That call just cannot be absolutely fast, so it shall not be called 
from AWT. Assigning to WatchPanel.setupContext().
Comment 5 Martin Entlicher 2009-10-01 15:26:53 UTC
Fixed in changeset:   147629:8dde4fa8546a
http://hg.netbeans.org/main/rev/8dde4fa8546a
Comment 6 Jaroslav Tulach 2009-10-02 10:01:21 UTC
That might help. Thanks.
Comment 7 Martin Entlicher 2009-10-07 10:46:34 UTC
FYI: this fix has caused regression issue #173914.
Comment 8 Quality Engineering 2009-10-09 22:59:38 UTC
Integrated into 'main-golden', will be available in build *200910091401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main-golden/rev/8dde4fa8546a
User: mentlicher@netbeans.org
Log: #173312 - Use RequestProcessor instead of Swing's Timer.