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 168962 - AWT thread blocked for 13.856 ms.
Summary: AWT thread blocked for 13.856 ms.
Status: RESOLVED DUPLICATE of bug 169863
Alias: None
Product: javaee
Classification: Unclassified
Component: Code (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: issues@javaee
URL: http://statistics.netbeans.org/except...
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2009-07-22 13:03 UTC by kawazu428
Modified: 2009-09-18 13:40 UTC (History)
1 user (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 154032


Attachments
nps snapshot (37.32 KB, bin/nps)
2009-07-22 13:03 UTC, kawazu428
Details
AWT queue (283.18 KB, image/png)
2009-07-24 17:14 UTC, Petr Jiricka
Details
The important part of AWT-EventQueue-1 thread (47.00 KB, image/png)
2009-07-24 18:02 UTC, Petr Cyhelsky
Details

Note You need to log in before you can comment on or make changes to this bug.
Description kawazu428 2009-07-22 13:03:39 UTC
Build: NetBeans IDE Dev (Build 200907161401)
VM: Java HotSpot(TM) Server VM, 14.0-b16, Java(TM) SE Runtime Environment, 1.6.0_14-b08
OS: Linux, 2.6.28-13-generic, i386

User Comments:
kawazu428: just working with .jsp files.


Maximal alredy reported slowness was 13856 ms, average is 13856
Comment 1 kawazu428 2009-07-22 13:03:49 UTC
Created attachment 85063 [details]
nps snapshot
Comment 2 Petr Jiricka 2009-07-24 17:05:29 UTC
Looks like opening JSP files can be slow. I am attaching a screenshot of the AWT queue snapshot, which shows that
opening JSPs happens in AWT, and it is slowed down by tag library parsing and such. Can I ask, how big is your project,
how many libraries do you have etc?

One weird thing about this report is that it says "AWT thread blocked for almost 14s", but in the attached profiler
snapshot, it is <4s. Which is still a lot, but the information submitted by the profiler seems to be wrong.
Comment 3 Petr Jiricka 2009-07-24 17:14:13 UTC
Created attachment 85191 [details]
AWT queue
Comment 4 Petr Cyhelsky 2009-07-24 17:55:10 UTC
Well, it imho isn't really wrong, it is just hard to read... - it is because time spend in java.lang.Object.wait is not
counted towards the total, so you must look for these waits and then find what exactly was AWT waiting for... in this
case there is only one Object.wait in the whole tree (under org.openide.text.CloneableEditorSupport.OpenDocumentImpl() )
so it seems that it would be good idea to look there - it seems the wait here was for the parsing which was actualy done
in another two threads:

Inactive RequestProcessor thread [Was:Timeable Event Queue Watch Dog/ org.netbeans.core.TimeableEventQueue ]
  - here the important part seem to be the org.netbeans.modules.parsing.spi.Scheduler

JSP Parsing

Here it seems to me lies the difference between the time spent in AWT as seen in snapshot and the actual time...
Comment 5 Petr Cyhelsky 2009-07-24 18:02:04 UTC
Created attachment 85195 [details]
The important part of AWT-EventQueue-1 thread
Comment 6 Petr Jiricka 2009-09-18 13:40:02 UTC
This is already fixed by Marek Fukala, see issue 169863. updateFileEncoding() is not called in AWT any more.


*** This issue has been marked as a duplicate of 169863 ***