Randomly getting unexpected bytes in the ChannelBuffer from test client with valid data
tnine
todd at spidertracks.com
Mon Jan 17 21:04:24 EST 2011
I have finally identified the issue through the addition of a
LenghtFieldBasedFrameDecoder before my custom decoder. I'm seeing the
following behavior.
1. Client connects and sends 71 bytes
2. LengthFieldBasedFrameDecoder is called, verifies the input is be 71 bytes
from the ushort in bytes 2 and 3.
3. SbdDecoder is called and passed the ChannelBuffer. The object is
correctly populated from the decoded bytes
4. SbdServerHandler is invoked. The object is stored and
e.getChannel().close() is called as the last operation of the method.
5. LengthDecoder is invoked again with a buffer of size 0.
Why is step 5 happening? If there are no more bytes and the final handler
has closed the channel, why does the pipeline get executed again?
Thanks,
Todd
--
View this message in context: http://netty-forums-and-mailing-lists.685743.n2.nabble.com/Randomly-getting-unexpected-bytes-in-the-ChannelBuffer-from-test-client-with-valid-data-tp5933385p5934256.html
Sent from the Netty User Group mailing list archive at Nabble.com.
More information about the netty-users
mailing list