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 252149 - org.netbeans.modules.xml.multiview.XmlMultiViewElement.getToolbarRepresentation: LowPerformance took 27998 ms.
Summary: org.netbeans.modules.xml.multiview.XmlMultiViewElement.getToolbarRepresentati...
Status: NEW
Alias: None
Product: platform
Classification: Unclassified
Component: Text (show other bugs)
Version: 8.0
Hardware: All All
: P3 normal (vote)
Assignee: Miloslav Metelka
URL:
Keywords: PERFORMANCE
Depends on:
Blocks:
 
Reported: 2015-04-28 23:20 UTC by Exceptions Reporter
Modified: 2015-05-06 15:47 UTC (History)
0 users

See Also:
Issue Type: DEFECT
Exception Reporter: 217010


Attachments
nps snapshot (296.85 KB, application/nps)
2015-04-28 23:21 UTC, Exceptions Reporter
Details

Note You need to log in before you can comment on or make changes to this bug.
Description Exceptions Reporter 2015-04-28 23:20:58 UTC
This bug was originally marked as duplicate of bug 232413, that is already resolved. This bug is still valid, so this seems to be another bug, but it might be related.

Build: NetBeans IDE 8.0 (Build 201403101706)
VM: Java HotSpot(TM) 64-Bit Server VM, 25.0-b70, Java(TM) SE Runtime Environment, 1.8.0-b132
OS: Windows 7

User Comments:
GUEST: eating a lot of memory from my machine compared to other IDE



Maximum slowness yet reported was 27998 ms, average is 27998
Comment 1 Exceptions Reporter 2015-04-28 23:21:01 UTC
Created attachment 153446 [details]
nps snapshot
Comment 2 Svata Dedic 2015-05-06 14:40:04 UTC
The profiler snapshot shows that the Multiview impl. tries to get an editorPanel using CloneableEditor.getEditorPane(), which
a/ MUST be called in AWT thread and
b/ is BLOCKING until the editor initializes offscreen (CloneableEditorInitializer.waitForFinishedInitialization)

I don't need the JEditorPane instance immediately, but the API does not provide a method (or I didn't find it) to find out that the editor pane is being initialized + potentially get notified when the init completes. Since getEditorPane() must be called in AWT, the caller risks UI freeze.
Comment 3 Vladimir Voskresensky 2015-05-06 15:47:49 UTC
(In reply to Svata Dedic from comment #2)
> The profiler snapshot shows that the Multiview impl. tries to get an
> editorPanel using CloneableEditor.getEditorPane(), which
> a/ MUST be called in AWT thread and
> b/ is BLOCKING until the editor initializes offscreen
> (CloneableEditorInitializer.waitForFinishedInitialization)
> 
> I don't need the JEditorPane instance immediately, but the API does not
> provide a method (or I didn't find it) to find out that the editor pane is
> being initialized
Have a look at NbDocument.findRecentEditorPane

> + potentially get notified when the init completes. 
have a look at CsmUtilities.openAtElement