Guntram Blohm created NETBEANS-6001:
---------------------------------------
Summary: Yaml parser eats memory up to 100% in case of syntax
errors
Key: NETBEANS-6001
URL: https://issues.apache.org/jira/browse/NETBEANS-6001
Project: NetBeans
Issue Type: Bug
Affects Versions: 12.4
Environment: Netbeans 12.4
Java jdk-16.0.1+9 from AdoptOpenJDK
Ubuntu 20.04
Both Netbeans and the JDK installed from their respective websites, not the
Ubuntu packet manager
Reporter: Guntram Blohm
When editing a YAML file, if there is a syntax error, netbeans eats up memory
until it reaches 100% of what it's assigned, at which point garbage collection
will use all CPU resources and netbeans becomes unresponsive.
To reproduce:
Create a new empty YAML file in any project
Enter the following text into the file:
{{some key:}}
{{ some value: "this is the value"}}
At this point, watch the widget that shows Netbeans' memory consumption, it
increases rapidly, until it reaches 100%. At this point, Java spends 99% of its
time in garbage collection, Netbeans becomes unresponsive (and if the Java
parameters permit using all cores, the system becomes sluggish as well).
I attached JProfiler to the JVM that was running netbeans and could confirm the
memory usage increase starting right after entering the invalid yaml. Taking a
heap dump showed 56 million instances of
`org.netbeans.modules.csl.spi.DefaultError`, as well as 56 million
`java.lang.String`s.
--
This message was sent by Atlassian Jira
(v8.3.4#803005)
---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]
For further information about the NetBeans mailing lists, visit:
https://cwiki.apache.org/confluence/display/NETBEANS/Mailing+lists