Hi Kevin, On 7/25/07, Kevin Smeltzer <[EMAIL PROTECTED]> wrote:
I am having a problem connecting to my a Mina based server from a Mina based client application.The client appreas to connect using this code: session = connectFuture.getSession(); The server log shows that the client connects and the client's sessionOpened(IoSession session) method is called: public void sessionOpened(IoSession session) throws Exception { clientListener.doConnect( session ); } In the clientListener.doConnect method the connection is still valid and everything seems to be working perfectly: public void doConnect( IoSession session) { System.out.println(session); client.sendRequest ( new bgClientRequest ( request ) ); } Then, in the sendRequest method, the session is null before I have even done any processing! What is happening? Does an IoSession member of my IoHandlerAdapter class get destroyed somehow? If so, why?
There might be some latency between the actual establishment of the connection and notification to the future. Please call future.join(); to ensure the notification is received. HTH, Trustin -- what we call human nature is actually human habit -- http://gleamynode.net/ -- PGP Key ID: 0x0255ECA6
