Avoid OutOfMemory error
Use the Netty's Channel.isWritable() to avoid of memory consumption (creating WriteAndFlush runanbles) in case of slow Clients. Modifdy the structure of moquette dispatcher to buffer (limited with config param) in case of slow Channels. Differentiate for the 3 qos classes. For QoS0 the messages can be stored in memory and once exceed the limit, drop the messages, probably the same can be done for the others classes
Any progress ?
It seems like this issue has been resolved by 0.9 but was not closed. We recently ran into an OutOfMemoryException (Direct Buffer Memory) when a receiver could not process published messages fast enough.
In this case, the broker would enqueue all published messages (even with QOS0) but since the receiver was not working fast enough, the queue was growing until the direct memory size (-XX:MaxDirectMemorySize=??M) has been reached - which then throws the OutOfMemoryException.
It still exists in 0.9 version .After running for several hours heap memory seems to keep increasing ,finally ,it throws a OutOfMemory error.
Any progress ?
@xinzhongtianxia Moquette has been reworked a lot since 0.9 version, now it's on 0.16, now there are queues and in flight windows, so this bug shouldn't happen again in this form, maybe if you experience some problem is another kind of bug, so please open a new issue.