Skip to content
This repository has been archived by the owner on Apr 13, 2020. It is now read-only.

java.lang.OutOfMemoryError: Java heap space #34

Open
ph1l opened this issue Nov 24, 2016 · 1 comment
Open

java.lang.OutOfMemoryError: Java heap space #34

ph1l opened this issue Nov 24, 2016 · 1 comment

Comments

@ph1l
Copy link
Contributor

ph1l commented Nov 24, 2016

long running server instance runs out of memory:

Exception in thread "hawtdispatch-DEFAULT-1" Exception in thread "hawtdispatch-DEFAULT-3" java.lang.OutOfMemoryError: Java heap space
java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.NullPointerException
        at org.fusesource.mqtt.client.CallbackConnection$7.run(CallbackConnection.java:414)
        at org.fusesource.hawtdispatch.transport.HeartBeatMonitor$3.run(HeartBeatMonitor.java:83)
        at org.fusesource.hawtdispatch.transport.HeartBeatMonitor$1.run(HeartBeatMonitor.java:62)
        at org.fusesource.hawtdispatch.internal.SerialDispatchQueue.run(SerialDispatchQueue.java:100)
        at org.fusesource.hawtdispatch.internal.pool.SimpleThread.run(SimpleThread.java:77)
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-1" java.lang.OutOfMemoryError: Java heap space
Exception in thread "hawtdispatch-DEFAULT-2" java.lang.OutOfMemoryError: Java heap space
@rob42
Copy link
Contributor

rob42 commented Nov 25, 2016

This can happen with Hawtio enabled, especially if you are running on a RPi. Hawtio uses quite a bit of ram when you are watching for a long time. I think the act of watching causes JMX or jolokia to hold onto all the messages etc, so they can be accessed.
Best option is to run hawtio only on a PC and set a decent amount of java memory (-Xmx1024M).
You can still use it on the RPi, as signalk-java will run the jolokia client when hawtio=false in the config. Then if you run the standalone version of hawtio you can connect remotely to the RPi.
See hawtio site

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants