Daniel van Mil created KARAF-7707:
-------------------------------------

             Summary: Eternal high CPU load when using Gogo plugin in web 
console
                 Key: KARAF-7707
                 URL: https://issues.apache.org/jira/browse/KARAF-7707
             Project: Karaf
          Issue Type: Question
          Components: webconsole
    Affects Versions: 4.4.0
            Reporter: Daniel van Mil


Sometimes when we open (and sometimes not even interact) with the Karaf web 
console Gogo plugin we get a very high CPU load (100%) from that point and 
Karaf never seems to recover from this.

Analysis of the showed us the following thread caused this:
"Thread-210" #16393 prio=5 os_prio=0 cpu=22819544.54ms elapsed=77820.53s 
tid=0x00007f21101c86c0 nid=0x406e runnable  [0x00007f20c319a000]
   java.lang.Thread.State: RUNNABLE
        at 
org.apache.karaf.webconsole.gogo.GogoPlugin$SessionTerminal.run(GogoPlugin.java:247)
        at java.lang.Thread.run([email protected]/Thread.java:833)

   Locked ownable synchronizers:
        - None
which points to the GogoPlugin.

A quick look at the gogo plugin shows some suspicious code: 
[https://github.com/apache/karaf/blob/main/webconsole/gogo/src/main/java/org/apache/karaf/webconsole/gogo/GogoPlugin.java#L55]

where the plugin could end in and endless loop causing high CPU load.

Strange thing is we can only find a few appearances of people who ran into 
this, like 
[https://community.talend.com/s/question/0D53p00007vCkucCAC/runtime-esb-high-cpu-load-caused-by-webconsole-gogo-?language=en_US]

It could be caused by the fact that we run Karaf on AWS and also behind an 
nginx, but by debugging Karaf locally we can also reproduce the issue somehow; 
the plugin sometimes receives strange characters and seems to go into an 
endless loop.

Is this a known issue?



--
This message was sent by Atlassian Jira
(v8.20.10#820010)

Reply via email to