HTTP server message followed by junk closes before reply
Trustin Lee
tlee at redhat.com
Thu Feb 12 12:44:49 EST 2009
On Fri, Feb 13, 2009 at 2:32 AM, Wade Poziombka <wpoziombka at hotmail.com> wrote:
> Wade Poziombka wrote:
>>
>> The issue is that the HTTP codec notes decoding error before the reply for
>> the first valid message is sent.
>
> I guess I was not clear... the problem is that the channel is closed before
> the reply goes back. It seems we should be able to defer the close. The
> fact that the codec detected the error is not an issue. The fact that it
> closes seems to be.
What about trying this?
ChannelFuture f = channel.write(lastResponse);
f.addListener(ChannelFutureListener.CLOSE);
then the connection will be closed *after* the last response is sent.
HTH,
Trustin
More information about the netty-users
mailing list