Can you copy your KeepAliveFilter code to a pastebin? I would like to look at it.
Are you using the current version of Mina? We had an issue relating the IoSession backlog a while back DIRMINA-1057 which makes sure that the counters are working correctly. On Thu, Jul 26, 2018 at 8:47 PM, Ming Lin <linuxmingc...@gmail.com> wrote: > Hi, > > I am trying to apply KeepAliveFilter to my application when > sessionIdle calls, but I ran into a problem that scheduledWriteMessages in > IoSession keeps increasing when KeepAlive message is sent. > > So, i debugged a little and found there might be a bug in the code, but I > need your help to see if my finding is correct. > > in HeadFilter.filterWrite line 886, it increases the count of > scheduledWriteMessages. code below > > if (!writeRequest.isEncoded()) { > > s.increaseScheduledWriteMessages(); > > } > > if writeRequest is a keepAlive request and code above will be called but in > KeepAliveFilter.messageSent doesn't fire next filter's messageSent, thus > the scheduleWriteMessages will keep increasing until socket disconnected > > Would like to know if this is a bug or misusing KeepAliveMessageFactory. > Thank you. >