directory-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Trustin Lee <trus...@gmail.com>
Subject Re: [mina] Problems with standard java.net Client
Date Sun, 24 Apr 2005 04:06:51 GMT
Hi,

2005/4/24, Luca Zago <luca.zago@gmail.com>:
> Hi,
> I am testing the MINA framework, in particular I am running the
> version 0,7-SNAPSHOT.
> I wanted only to explore the API so I ran the EchoServer Example, but
> I wanted to use a client based on normal java.net socket classes:
> 
> echoSocket = new Socket("localhost", 8080);
>            out = new PrintWriter(echoSocket.getOutputStream(), true);
>            in = new BufferedReader(new InputStreamReader(
>                    echoSocket.getInputStream()));
>        } catch (UnknownHostException e) {
>        } catch (IOException e) {
> 
>        }
>        BufferedReader stdIn = new BufferedReader(
>                new InputStreamReader(System.in));
>        String userInput;
> 
>        while ((userInput = stdIn.readLine()) != null) {
>            out.println(userInput);
>            System.out.println("echo: " + in.readLine());
>        }
> I noticed that he can create a session on the server, but no message
> arrive, the message methods on the server has been never called. Does
> Mina support standard client? Or is it possible to communicate with it
> only with clients built on Mina API?

MINA, of course, works with standard client.  I've just tested Echo
server example with your code, and it workd great?  Strange...

Could you tell me exact environment you're running?

Thanks,
Trustin
-- 
what we call human nature is actually human habit
--
http://gleamynode.net/

Mime
View raw message