I've decided to describe problem which I met using Netty library. Currently I work on Android client, that send and receive data through websocket and that was the reason why Netty library was chosen.
Now I have NIO mechanism, which handle SSL connection using websockets. Everything works fine, expect one a little bit unusual scenario - when Android client and the server send data to each other in the same time (few requests per second), after a while 'write' operation's ChannelFutureListener never calls 'operationComplete'.
I've made some research and found information that this kind of problem can occur when ssl handshake isn't finished . However I think this scenario doesn't apply to my situation when data is received and sent properly until this extreme situation.
Have you any idea where I should looking for solution for this problem?
My research:
At first, I found that this problem occurs on Netty4 too
but unfortunately Netty3 hasn't channel method like 'writeAndFlush'.
Then I found bug:Issue 1823 which was fixed by this commit and was described here, which could be closely related to my problem. Unfortunately I have problems with build Netty to jar - I have problems with HashedWheelTimer, which calls NoClassDefFoundError everytime when I want to use it. Is it fault how I build this project or is it this branch internal problem? Unfortunately the newest Netty on maven repository (3.9.0.Final) doesn't include this fix.
I've observer strange behaviour of my application: when 'operationComplete' isn't called and I close channel (channel.close()), I get few 'operationComplete' calls from every unfinished 'write' operation. Moreover when I observe state of threads in pool, after problem occurs thread which is responsible for channel is in 'WAIT' state. I am not sure what is a result and what is a cause.
I will really appreciate any ideas what can I do.
PS. Move to Netty4/5 is latest considered option - I suppose it will cost me a lot of time.
Krzysztof Skrzynecki