The HTTP Client monitor displays the HTTP response body in a JEditor. If the response body is not formatted i.e all the
content is in single line, then the editor has performance issues while rendering the files causing Netbeans to hang.
Please see issue 148996 for:
1) Stack traces
2) Profiler call tree
3) Profiler hot spots
4) A sample project to reproduce the issue
Please note we implemented a workaround for issue 148996 so to see this issue you need to get version 104156 of
Please email me if you need any help in reproducing the issue
Milo, please evaluate. Thanks
I was able to reproduce the problem in current dev build.
There does not seem to be anything wrong but I will continue profiling of the highlighting layers to search for
I personally don't see what's a benefit for the user to see 100K of text on a single line. IMHO the line should be
reformatted into a regular indented text so that the user can orient in it.
I'm downgrading to P3 since this is not a typical editing usecase.
I have made some additional profiling. There are
1) 103389 chars in the js-script-min.js document.
2) 7 BaseDocument.insertString() invocations (there is a buffer with 16384 chars for insertions).
These could be collapsed into a single insert by reallocating the buffer before the actual insert but I consider that
3) 38804 tokens in the document.
I see two problems:
a) Since almost all the chars are on a single line each repetitive insertion in 2) causes re-measurement of the
particular line in the view hierarchy (DrawEngineLineView.getPreferredSpan() gets called leading to DrawEngine.draw()
called for measurements).
- A new view hierarchy (issue 121357) should improve the situation considerably since the views will maintain their
span internally so there will be no additional re-measurements done.
b) Token hierarchy is updated after each sub-insert in 2) leading to repetitive updates of syntax highlighting layer.
- This should be improved by switching the TH off before document loading and on after the loading - issue 150204
(planned for 7.0).
I have added some logging of syntax highlighting and token hierarchy events and views rebuilding:
Integrated into 'main-golden', will be available in build *200811071401* on http://bits.netbeans.org/dev/nightly/ (upload may still be in progress)
User: Miloslav Metelka <email@example.com>
Bug prior to 7.0, not touched for the last 2 years --> P4.
I think this was fixed long ago by Mila.