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 169480 - 3531 ms - JavaRefactoring isEnabled() check too slow
Summary: 3531 ms - JavaRefactoring isEnabled() check too slow
Status: RESOLVED FIXED
Alias: None
Product: java
Classification: Unclassified
Component: Refactoring (show other bugs)
Version: 6.x
Hardware: All All
: P3 blocker (vote)
Assignee: Jan Pokorsky
URL: http://statistics.netbeans.org/except...
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2009-07-29 15:53 UTC by Oleg Khokhlov
Modified: 2009-11-11 08:05 UTC (History)
2 users (show)

See Also:
Issue Type: DEFECT
Exception Reporter: 154493


Attachments
nps snapshot (33.41 KB, bin/nps)
2009-07-29 15:54 UTC, Oleg Khokhlov
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Oleg Khokhlov 2009-07-29 15:53:51 UTC
Build: NetBeans IDE Dev (Build 200907290201)
VM: Java HotSpot(TM) Client VM, 11.3-b02, Java(TM) SE Runtime Environment, 1.6.0_13-b02
OS: Windows XP, 5.1, x86

User Comments:
ovk: right click on method in java editor


Maximum slowness yet reported was 3531 ms, average is 3531
Comment 1 Oleg Khokhlov 2009-07-29 15:54:02 UTC
Created attachment 85477 [details]
nps snapshot
Comment 2 Jesse Glick 2009-07-29 17:11:59 UTC
JavaRefactoringGlobalAction should probably not be doing exotic enablement checks on EQ.

If an exact containment check is necessary, then probably WONTFIX: SourceGroup.contains will be slow the very first time
it is invoked on a group with a nontrivial includes list (or for the first time after changing the includes list), since
e.g. includes="**/api/" means that a check for "org/netbeans/" must be true iff some package like
org.netbeans.something.api exists. (In this case a *.java file is being queried, for which the knownIncludes list is not
needed, but sooner or later the same computation would have been needed anyway.)
Comment 3 Jan Pokorsky 2009-11-11 08:04:18 UTC
Popup menu action providers are now initialized by JavaEditorWarmUpTask now.

The SourceGroup query is used as a work around until someone fix bug 143542.