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 176870 - 7s - no new reports
Summary: 7s - no new reports
Status: CLOSED WORKSFORME
Alias: None
Product: ide
Classification: Unclassified
Component: Performance (show other bugs)
Version: 3.x
Hardware: All All
: P3 normal with 1 vote (vote)
Assignee: Jaroslav Tulach
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2009-11-15 22:20 UTC by armandojaga
Modified: 2011-05-25 11:39 UTC (History)
4 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 159556


Attachments
nps snapshot (256.00 KB, application/nps)
2009-11-15 22:20 UTC, armandojaga
Details

Note You need to log in before you can comment on or make changes to this bug.
Description armandojaga 2009-11-15 22:20:53 UTC
Build: NetBeans IDE 6.8 Beta (Build 200910221137)
VM: Java HotSpot(TM) Client VM, 14.3-b01, Java(TM) SE Runtime Environment, 1.6.0_17-b04
OS: Windows XP, 5.1, x86

User Comments:
GUEST: Clicked on <Toggle Bookmark>

GUEST: Opened java src file for the first time after it was renamed. Possibly it had not been previously scanned?

GUEST: Just opening a folder

GUEST: - starting netbeans (incl. opening 5 projects)
- again ~5000 ms while writing the line above, fh :(


Maximum slowness yet reported was 46484 ms, average is 14044
Comment 1 armandojaga 2009-11-15 22:20:58 UTC
Created attachment 91064 [details]
nps snapshot
Comment 2 Jiri Skrivanek 2009-11-16 00:39:40 UTC
Probably JavaSource.forFileObject() in OpenedEditors.stateChanged() should be moved out of AWT thread because it can be slow while accessing file system.

org.netbeans.api.java.source.support.OpenedEditors$1.propertyChange(): 74 / 0
org.netbeans.api.java.source.support.OpenedEditors.stateChanged(): 74 / 0
org.netbeans.api.java.source.JavaSource.forFileObject(): 74 / 0
org.openide.filesystems.FileUtil.getMIMEType(): 74 / 0
Comment 3 Exceptions Reporter 2009-11-23 04:56:09 UTC
This bug already has 20 duplicates 
see http://statistics.netbeans.org/exceptions/detail.do?id=159556
Comment 4 Jan Lahoda 2009-11-23 06:25:43 UTC
Sorry, I not going to evaluate this one. I did not go through all 20 duplicates, but from those that I saw (~10), only the one attached to the bugzilla
bug was related to java.source (some related to parsing.api though). The bug as a whole should be therefore evaluated somewhere else.
Given that the reports started sometime in September, and all end-up in FileSystems library, there may be some underlying regression in this
library (e.g. some cache removed/broken - note that in the attached case (in java.source), the file was already opened in the editor,
and so its mime type should be already know, right?). Otherwise, the slowness reporter duplicated a bunch of unrelated
reports and the mess needs to be cleaned up manually. I simply do not have time to do this. Also, the duplicating facility of the slowness reported should
be fixed not to duplicate unrelated reports.

I am going to improve the behavior of JavaSource.forFileObject, but that's certainly not going to help with the other reports that are not related to java.source.
Comment 5 Quality Engineering 2009-11-24 19:02:53 UTC
Integrated into 'main-golden', will be available in build *200911241400* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
Changeset: http://hg.netbeans.org/main/rev/30fa286f101d
User: Jan Lahoda <jlahoda@netbeans.org>
Log: #176870: slow mime resolvers should not be used to compute FileObject's mimeType for the purposes of JavaSource.forFileObject.
Comment 6 Tomas Pavek 2010-03-17 12:26:27 UTC
Looked at the longest snapshots (above 10s), they are all FS related.

FileObjectFactory.getFileObject
- http://statistics.netbeans.org/exceptions/exception.do?id=280336 (waiting in Mutex)
- http://statistics.netbeans.org/exceptions/exception.do?id=288699 (WinNTFileSystem.getBooleanAttributes)
- http://statistics.netbeans.org/exceptions/exception.do?id=300617 (waiting in Mutex)

URLMapper.findURL -> Win32FileSystem.canonicalize
- http://statistics.netbeans.org/exceptions/exception.do?id=278029 (one call ~20s)
- http://statistics.netbeans.org/exceptions/exception.do?id=294586 (one call ~9s)
- http://statistics.netbeans.org/exceptions/exception.do?id=294642 (one call ~21s)

BTW no new reports here since November 2009.
Comment 7 Jaroslav Tulach 2010-03-22 14:27:27 UTC
If there are no new reports, then let's close as "workforme".