You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@mina.apache.org by Dupont jean <do...@yahoo.fr> on 2007/06/06 15:01:13 UTC

Re : Problems running server

Your problem is simple :

acceptor.bind(new InetSocketAddress("localhost", 7070), new ReverseEchoServerHandler(), cfg);

is non blocking so when it finishes it then executes  acceptor.unbindAll(); instruction and your server is shutdown try adding the following line 
while (true) ; 
and you should be able to contact your server with your putty client 

Regards,
Edouard De Oliveira

----- Message d'origine ----
De : Karsten Ohme <wi...@t-online.de>
À : dev@mina.apache.org
Envoyé le : Mercredi, 6 Juin 2007, 13h55mn 53s
Objet : Problems running server

Hi,

I want to use MINA for implementing a tunnel, but I have problems to run 
it. I experience the following:

I bind the SocketAcceptor
the run method of the Worker class is executed:

select returns because wakeup() is called by bind()
the request is registered with registerNew()
nKeys is 0
the keys are cancelled
during the second run:
select returns
keys are cancelled
selector keys are empty
registerQueue is empty
cancelQueue is empty

run exits

the program waits a while in some Executor... method and the server exits

I have tried this also with a simple ReverseSEchoerver example from your site (updated to the 1.1 API). It shows teh same result. I want to connect with putty at 
port 
7070 but putty does simply exit.

I have attached the ReverseEchoServer sources (for Eclipse).

Regatrds,
Karsten










      _____________________________________________________________________________ 
Ne gardez plus qu'une seule adresse mail ! Copiez vos mails vers Yahoo! Mail