Structured message reading problem in Netty.

manishr22 manishr22 at gmail.com
Fri May 1 08:40:36 EDT 2009


Thanks for your suggestion, I will try working accordingly. Since Trustin
will be back n 6th May. i will try finding some solution in the meanwhile
otherwise will wait for Trustin comments.


Regards
Manish 

Frederic Bregier wrote:
> 
> Hi,
> 
> Maybe Trustin could have an idea on how to read all data send to the wired
> (and received) even if the connection is down. 
> I think it is doable using OrderedMemoryAwareThreadPoolExecutor inserted
> in your pipeline (same executor for all channel) just after you codec
> since it should ordered all events, even the disconnection so that the
> final handler should get all events in order (all packets first then the
> disconnection). But maybe I'm wrong...
> 
> HTH,
> Frederic
>   ----- Original Message ----- 
>   From: manishr22 (via Nabble) 
>   To: Frederic Bregier 
>   Sent: Friday, May 01, 2009 12:54 PM
>   Subject: Re: Structured message reading problem in Netty.
> 
> 
>   Hi Frederic, 
> 
>   Thanks for your clarification. But the problem is, we are trying to make
> a asynchronous TCP/Ip communication then there should be any dependency on
> client. 
> 
>   In my existing code what you said is exactly right. 
> 
>   - I have my normal client (non-netty) it creates TCP connection and send
> as much data it wants and terminates. 
>   - I believe as much data client has written on the socket should be read
> by server. 
>   - In my case i have several such client and they can send as many number
> of message to the server they want. how come i understand when to send
> back "end of transmission" to the client, then only client should
> disconnect. 
>   - The workaround is my client should send "bye/final" after all its
> messages then in the echo from server send back the same and then only i
> should close connection from client. But this way i am synchronizing my
> server with client. 
>   - If i have my server with normal socket, even though my client
> connection goes down, server will still be reading all buffered socket
> data without any problem. 
>   - In what sense netty is differentiating here. 
> 
>   Regards, 
>   Manish
> 

-- 
View this message in context: http://n2.nabble.com/Structured-message-reading-problem-in-Netty.-tp2682454p2752912.html
Sent from the Netty User Group mailing list archive at Nabble.com.




More information about the netty-users mailing list