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.
Current LocaleSupport in editor is slow and does not scale well. In order to get a localized string it iterates through registered localizers until it find the value for given key. These localizers have to be registered during startup. Obviously we load more classes than neceseary during start. We touches parts of IDE that are not needed (I did nothing with XML/properties/JSP and their localizers are queried).
Yes we are aware of this and we would like to get rid of the LocaleSupport in the future completely.
Also it forces us to use longer keys to avoid clashes in their names - so it affects memory usage. When will you remove it?
Any progres on this? It is apparently API that should be reworked it does not scale. The more editor the longer time spent in this code. The flow is controled by MisingResourceException throw often with stack depth 60 or more so these exceptions are not cheap.
Currently editor opening suffers from this because toolbar creating does many calls to localization support to get action name (and perhaps oher attributes). 20-25% of time needed to open XML is spent in createToolbar(). Increasing priority to P2 and according to Mila there is a chance to fix this for 5.0.
I've been evaluating solution to this in the past already so I'll attempt to fix this.
Committing a fix for the core editor. Now the LocaleSupport is no longer queried during startup with opened java or xml file so this should no longer be a blocker and I consider this issue fixed. Still the LocaleSupport is retained to not break the backward compatibility and still e.g. popup menu items query it. I have entered issue 70171 to cover this. I have added debug property for tracing LocaleSupport calls. It's -J-Dnetbeans.debug.editor.localesupport=true It outputs queried key and resulting value and also the bundle class (helps to find the package containing the matching bundle) and the stacktrace from which the call originated. Checking in libsrc/org/netbeans/editor/ActionFactory.java; /cvs/editor/libsrc/org/netbeans/editor/ActionFactory.java,v <-- ActionFactory.java new revision: 1.75; previous revision: 1.74 done Checking in libsrc/org/netbeans/editor/Annotations.java; /cvs/editor/libsrc/org/netbeans/editor/Annotations.java,v <-- Annotations.java new revision: 1.27; previous revision: 1.26 done Checking in libsrc/org/netbeans/editor/BaseAction.java; /cvs/editor/libsrc/org/netbeans/editor/BaseAction.java,v <-- BaseAction.java new revision: 1.38; previous revision: 1.37 done Checking in libsrc/org/netbeans/editor/BaseKit.java; /cvs/editor/libsrc/org/netbeans/editor/BaseKit.java,v <-- BaseKit.java new revision: 1.150; previous revision: 1.149 done Checking in libsrc/org/netbeans/editor/Bundle.properties; /cvs/editor/libsrc/org/netbeans/editor/Bundle.properties,v <-- Bundle.properties new revision: 1.66; previous revision: 1.65 done Checking in libsrc/org/netbeans/editor/DocumentFinder.java; /cvs/editor/libsrc/org/netbeans/editor/DocumentFinder.java,v <-- DocumentFinder.java new revision: 1.13; previous revision: 1.12 done Checking in libsrc/org/netbeans/editor/FindSupport.java; /cvs/editor/libsrc/org/netbeans/editor/FindSupport.java,v <-- FindSupport.java new revision: 1.76; previous revision: 1.75 done Checking in libsrc/org/netbeans/editor/GlyphGutter.java; /cvs/editor/libsrc/org/netbeans/editor/GlyphGutter.java,v <-- GlyphGutter.java new revision: 1.52; previous revision: 1.51 done Checking in libsrc/org/netbeans/editor/GuardedDocument.java; /cvs/editor/libsrc/org/netbeans/editor/GuardedDocument.java,v <-- GuardedDocument.java new revision: 1.19; previous revision: 1.18 done Checking in libsrc/org/netbeans/editor/KeySequenceInputPanel.form; /cvs/editor/libsrc/org/netbeans/editor/KeySequenceInputPanel.form,v <-- KeySequenceInputPanel.form new revision: 1.4; previous revision: 1.3 done Checking in libsrc/org/netbeans/editor/KeySequenceInputPanel.java; /cvs/editor/libsrc/org/netbeans/editor/KeySequenceInputPanel.java,v <-- KeySequenceInputPanel.java new revision: 1.6; previous revision: 1.5 done RCS file: /cvs/editor/libsrc/org/netbeans/editor/LocalBaseAction.java,v done Checking in libsrc/org/netbeans/editor/LocalBaseAction.java; /cvs/editor/libsrc/org/netbeans/editor/LocalBaseAction.java,v <-- LocalBaseAction.java initial revision: 1.1 done Checking in libsrc/org/netbeans/editor/LocaleSupport.java; /cvs/editor/libsrc/org/netbeans/editor/LocaleSupport.java,v <-- LocaleSupport.java new revision: 1.14; previous revision: 1.13 done Checking in libsrc/org/netbeans/editor/MacroDialogSupport.java; /cvs/editor/libsrc/org/netbeans/editor/MacroDialogSupport.java,v <-- MacroDialogSupport.java new revision: 1.8; previous revision: 1.7 done Checking in libsrc/org/netbeans/editor/MacroSavePanel.form; /cvs/editor/libsrc/org/netbeans/editor/MacroSavePanel.form,v <-- MacroSavePanel.form new revision: 1.4; previous revision: 1.3 done Checking in libsrc/org/netbeans/editor/MacroSavePanel.java; /cvs/editor/libsrc/org/netbeans/editor/MacroSavePanel.java,v <-- MacroSavePanel.java new revision: 1.6; previous revision: 1.5 done Checking in libsrc/org/netbeans/editor/StatusBar.java; /cvs/editor/libsrc/org/netbeans/editor/StatusBar.java,v <-- StatusBar.java new revision: 1.47; previous revision: 1.46 done Checking in libsrc/org/netbeans/editor/Utilities.java; /cvs/editor/libsrc/org/netbeans/editor/Utilities.java,v <-- Utilities.java new revision: 1.77; previous revision: 1.76 done Checking in libsrc/org/netbeans/editor/ext/Completion.java; /cvs/editor/libsrc/org/netbeans/editor/ext/Completion.java,v <-- Completion.java new revision: 1.40; previous revision: 1.39 done Checking in libsrc/org/netbeans/editor/ext/CompletionJavaDoc.java; /cvs/editor/libsrc/org/netbeans/editor/ext/CompletionJavaDoc.java,v <-- CompletionJavaDoc.java new revision: 1.37; previous revision: 1.36 done Checking in libsrc/org/netbeans/editor/ext/ExtKit.java; /cvs/editor/libsrc/org/netbeans/editor/ext/ExtKit.java,v <-- ExtKit.java new revision: 1.65; previous revision: 1.64 done Checking in libsrc/org/netbeans/editor/ext/FindDialogPanel.form; /cvs/editor/libsrc/org/netbeans/editor/ext/FindDialogPanel.form,v <-- FindDialogPanel.form new revision: 1.11; previous revision: 1.10 done Checking in libsrc/org/netbeans/editor/ext/FindDialogPanel.java; /cvs/editor/libsrc/org/netbeans/editor/ext/FindDialogPanel.java,v <-- FindDialogPanel.java new revision: 1.14; previous revision: 1.13 done Checking in libsrc/org/netbeans/editor/ext/FindDialogSupport.java; /cvs/editor/libsrc/org/netbeans/editor/ext/FindDialogSupport.java,v <-- FindDialogSupport.java new revision: 1.73; previous revision: 1.72 done Checking in libsrc/org/netbeans/editor/ext/GotoDialogPanel.form; /cvs/editor/libsrc/org/netbeans/editor/ext/GotoDialogPanel.form,v <-- GotoDialogPanel.form new revision: 1.7; previous revision: 1.6 done Checking in libsrc/org/netbeans/editor/ext/GotoDialogPanel.java; /cvs/editor/libsrc/org/netbeans/editor/ext/GotoDialogPanel.java,v <-- GotoDialogPanel.java new revision: 1.13; previous revision: 1.12 done Checking in libsrc/org/netbeans/editor/ext/GotoDialogSupport.java; /cvs/editor/libsrc/org/netbeans/editor/ext/GotoDialogSupport.java,v <-- GotoDialogSupport.java new revision: 1.24; previous revision: 1.23 done Checking in libsrc/org/netbeans/editor/ext/ListCompletionView.java; /cvs/editor/libsrc/org/netbeans/editor/ext/ListCompletionView.java,v <-- ListCompletionView.java new revision: 1.16; previous revision: 1.15 done Checking in libsrc/org/netbeans/editor/ext/ScrollJavaDocPane.java; /cvs/editor/libsrc/org/netbeans/editor/ext/ScrollJavaDocPane.java,v <-- ScrollJavaDocPane.java new revision: 1.11; previous revision: 1.10 done Checking in libsrc/org/netbeans/editor/ext/ToolTipSupport.java; /cvs/editor/libsrc/org/netbeans/editor/ext/ToolTipSupport.java,v <-- ToolTipSupport.java new revision: 1.29; previous revision: 1.28 done Checking in src/org/netbeans/modules/editor/NbEditorKit.java; /cvs/editor/src/org/netbeans/modules/editor/NbEditorKit.java,v <-- NbEditorKit.java new revision: 1.95; previous revision: 1.94 done Checking in src/org/netbeans/modules/editor/NbLocalizer.java; /cvs/editor/src/org/netbeans/modules/editor/NbLocalizer.java,v <-- NbLocalizer.java new revision: 1.9; previous revision: 1.8 Checking in src/org/netbeans/modules/editor/java/JavaKit.java; /cvs/java/editor/src/org/netbeans/modules/editor/java/JavaKit.java,v <-- JavaKit.java new revision: 1.28; previous revision: 1.27