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.
During lookup initialization VariableIO.getConfigurationLabelAndOS is called and spents a lot of time in VcsUtilities.getBundleString that performs a heavy string processing (111ms on my Ultra60 when running under Sun Analyzer that does sampling every 1ms). Maybe we can optimize it. Store the created result in a temp StringBuffer to avoid many new String instances that are searched again and again for another occurence of 'getBundle' pattern. Perhaps couple of other minor optimizations to avoid repeated calls to String.charAt in one loop iteration and similar.
True. That reminds me, that I was thinking about this also when fixing issue #38108. Perhaps a fix of this can help to reduce the time that is spent in #38108, but nonetheless it will not be sufficient.
/cvs/vcscore/src/org/netbeans/modules/vcscore/util/VcsUtilities.java,v <-- VcsUtilities.java new revision: 1.37; previous revision: 1.36 improved a bit. I will look in analyzer again to see if it is worth to do more.
This has impact on issue #38108. I'll try to do something with it, more complex strings (composed of several messages loaded from ResourceBundle) take several milliseconds.
Fixed in trunk. A new, more efficient, method VcsUtilities.getBundleString() was written. The profile can define a list of resource bundles, which are temporarily cached for reading of localized messages. Also the keyword for localized message in XML profile is much shorter. In InputDescriptors we do not load localized message when reading command properties. These are resolved later, when the input descriptor is parsed. Checking in vcscore/src/org/netbeans/modules/vcscore/commands/CommandCustomizationSupport.java; /cvs/vcscore/src/org/netbeans/modules/vcscore/commands/CommandCustomizationSupport.java,v <-- CommandCustomizationSupport.java new revision: 1.28; previous revision: 1.27 done Processing log script arguments... More commits to come... Checking in vcscore/src/org/netbeans/modules/vcscore/util/VariableInputDescriptor.java; /cvs/vcscore/src/org/netbeans/modules/vcscore/util/VariableInputDescriptor.java,v <-- VariableInputDescriptor.java new revision: 1.21; previous revision: 1.20 done Checking in vcscore/src/org/netbeans/modules/vcscore/util/VcsUtilities.java; /cvs/vcscore/src/org/netbeans/modules/vcscore/util/VcsUtilities.java,v <-- VcsUtilities.java new revision: 1.38; previous revision: 1.37 done Processing log script arguments... More commits to come... Checking in vcsgeneric/src/org/netbeans/modules/vcs/advanced/ProfileContentHandler.java; /cvs/vcsgeneric/src/org/netbeans/modules/vcs/advanced/ProfileContentHandler.java,v <-- ProfileContentHandler.java new revision: 1.3; previous revision: 1.2 done Checking in vcsgeneric/src/org/netbeans/modules/vcs/advanced/ProfilesFactory.java; /cvs/vcsgeneric/src/org/netbeans/modules/vcs/advanced/ProfilesFactory.java,v <-- ProfilesFactory.java new revision: 1.12; previous revision: 1.11 done Checking in vcsgeneric/src/org/netbeans/modules/vcs/advanced/UserConditionedVariablesPanel.java; /cvs/vcsgeneric/src/org/netbeans/modules/vcs/advanced/UserConditionedVariablesPanel.java,v <-- UserConditionedVariablesPanel.java new revision: 1.9; previous revision: 1.8 done Checking in vcsgeneric/src/org/netbeans/modules/vcs/advanced/VcsCustomizer.java; /cvs/vcsgeneric/src/org/netbeans/modules/vcs/advanced/VcsCustomizer.java,v <-- VcsCustomizer.java new revision: 1.137; previous revision: 1.136 done Processing log script arguments... More commits to come... Checking in vcsgeneric/src/org/netbeans/modules/vcs/advanced/commands/UserCommandIO.java; /cvs/vcsgeneric/src/org/netbeans/modules/vcs/advanced/commands/UserCommandIO.java,v <-- UserCommandIO.java new revision: 1.20; previous revision: 1.19 done Processing log script arguments... More commits to come... Checking in vcsgeneric/src/org/netbeans/modules/vcs/advanced/variables/VariableIO.java; /cvs/vcsgeneric/src/org/netbeans/modules/vcs/advanced/variables/VariableIO.java,v <-- VariableIO.java new revision: 1.25; previous revision: 1.24 done Processing log script arguments... More commits to come... Checking in vcsgeneric/src/org/netbeans/modules/vcs/profiles/config/vcs-configuration-1_1.dtd; /cvs/vcsgeneric/src/org/netbeans/modules/vcs/profiles/config/vcs-configuration-1_1.dtd,v <-- vcs-configuration-1_1.dtd new revision: 1.3; previous revision: 1.2 done Processing log script arguments... More commits to come... Checking in vcsgeneric/profiles/cvsprofiles/src/org/netbeans/modules/vcs/profiles/cvsprofiles/config/cvs.xml; /cvs/vcsgeneric/profiles/cvsprofiles/src/org/netbeans/modules/vcs/profiles/cvsprofiles/config/cvs.xml,v <-- cvs.xml new revision: 1.79; previous revision: 1.78 done Processing log script arguments... More commits to come... Checking in vcsgeneric/profiles/pvcs/src/org/netbeans/modules/vcs/profiles/pvcs/config/pvcs.xml; /cvs/vcsgeneric/profiles/pvcs/src/org/netbeans/modules/vcs/profiles/pvcs/config/pvcs.xml,v <-- pvcs.xml new revision: 1.33; previous revision: 1.32 done Checking in vcsgeneric/profiles/pvcs/src/org/netbeans/modules/vcs/profiles/pvcs/config/pvcsLoc_XX.xml; /cvs/vcsgeneric/profiles/pvcs/src/org/netbeans/modules/vcs/profiles/pvcs/config/pvcsLoc_XX.xml,v <-- pvcsLoc_XX.xml new revision: 1.29; previous revision: 1.28 done Processing log script arguments... More commits to come... Checking in vcsgeneric/profiles/vss/src/org/netbeans/modules/vcs/profiles/vss/config/vss.xml; /cvs/vcsgeneric/profiles/vss/src/org/netbeans/modules/vcs/profiles/vss/config/vss.xml,v <-- vss.xml new revision: 1.29; previous revision: 1.28 done Checking in vcsgeneric/profiles/vss/src/org/netbeans/modules/vcs/profiles/vss/config/vssLoc_XX.xml; /cvs/vcsgeneric/profiles/vss/src/org/netbeans/modules/vcs/profiles/vss/config/vssLoc_XX.xml,v <-- vssLoc_XX.xml new revision: 1.23; previous revision: 1.22 done Processing log script arguments... More commits to come... Checking in www/www/dtds/vcs-configuration-1_1.dtd; /cvs/www/www/dtds/vcs-configuration-1_1.dtd,v <-- vcs-configuration-1_1.dtd new revision: 1.3; previous revision: 1.2 done