mina-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benjamin WATINE - Logixys <b.wat...@logixys.fr>
Subject Running Mina client for MinaTimeServer
Date Mon, 23 Feb 2009 13:07:30 GMT
Hi the list,

First post here ; I'm new to mina, so please forgive my possibly stupid 
questions !
I've set up the MinaTimeServer for testing purpose, it's ok, I can use 
it with telnet.
So now, I try to make a little client with mina, but it doesn't work. No 
objet seems to be written to the session (MinaTimeServer don't receive 

Here's the piece of code for client handler :

	public void sessionOpened(IoSession session) {
		StringBuffer message = new 
	public void messageReceived(IoSession session, Object message) {
		IoBuffer buf = (IoBuffer) message;
		// Print out read buffer content.
		while (buf.hasRemaining()) {
			System.out.print((char) buf.get());

What's wrong ? How can I send data to the server ? session.write() isn't 
enought, I must flush or anything like that ?

I'm in localhost, port is ok, iptable is not running.

Thank you !


View raw message