Skip to content

OutOfMemoryError: Direct buffer memory #34

Description

@dfranssen

When there is no internet connection, I get the OOM exception below after a while. Is it possible that the read/write buffers should be released first in the initializeChannel?

Exception in thread "hawtdispatch-DEFAULT-4" java.lang.OutOfMemoryError: Direct buffer memory
	at java.nio.Bits.reserveMemory(Bits.java:666)
	at java.nio.DirectByteBuffer.<init>(DirectByteBuffer.java:123)
	at java.nio.ByteBuffer.allocateDirect(ByteBuffer.java:311)
	at org.fusesource.hawtdispatch.transport.SslTransport.initializeChannel(SslTransport.java:250)
	at org.fusesource.hawtdispatch.transport.TcpTransport.connecting(TcpTransport.java:425)
	at org.fusesource.hawtdispatch.transport.SslTransport.connecting(SslTransport.java:195)
	at org.fusesource.mqtt.client.CallbackConnection.createTransport(CallbackConnection.java:286)
	at org.fusesource.mqtt.client.CallbackConnection$4.run(CallbackConnection.java:237)
	at org.fusesource.hawtdispatch.internal.TimerThread$2.run(TimerThread.java:155)
	at org.fusesource.hawtdispatch.internal.SerialDispatchQueue.run(SerialDispatchQueue.java:100)
	at org.fusesource.hawtdispatch.internal.pool.SimpleThread.run(SimpleThread.java:77)

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions