users@glassfish.java.net

Re: Missing ClientAbortException on small responses

From: Jeanfrancois Arcand <Jeanfrancois.Arcand_at_Sun.COM>
Date: Wed, 29 Oct 2008 15:40:36 -0400

Salut,

paab_at_mbricks.no wrote:
> OK, this sounds plausible for what I have seen on Tomcat, but on Glassfish I
> don't even get an IOException if I transfer a 100 kbyte large response and
> drop the connection after receiving half.

You need to increase the log level...displaying the IOException in the
log by default cause all kind of false firedrill ;-) Have you tried
increasing the log level?


>
> I am also guessing that since the underlying transport mechanism is TCP
> there must be a way to check that a response as been fully read be the
> client.

No, with NIO once you flushed the bytes to the OS level, you cannot find
if the client read the bytes or not.


I do not want to make a TCP like transaction support on top of the
> standard http protocol.

What are you exactly trying to do?

Thanks

-- Jeanfrancois


>
> Pål
>
>
>
> Jeanfrancois Arcand-2 wrote:
>> Salut,
>>
>> paab_at_mbricks.no wrote:
>>> I need to know whether the response created is received by the client. If
>>> the
>>> client for some reason drops the connection during the write back process
>>> I
>>> was excepting a ClientAbortException, but this do not occur for all
>>> responses. I'm guess it has something to do with the size of the
>>> response?
>> No necessarily. The ClientAbortException occurs when the server is in
>> the process of writing the response, but the client close the
>> connection. If the server was able to write the bytes inside OS buffer,
>> and then the client close the connection, you will not see the exception.
>>
>> Can you turn the webcontainer log level to high and see if you get more
>> ClientAbortException? I doubt, but just in case.
>>
>> A+
>>
>> -- Jeanfrancois
>>
>>
>>> Any idea how to get this exception also for responses of such a couple of
>>> bytes?
>>>
>>> Pål
>>>
>>>
>> ---------------------------------------------------------------------
>> To unsubscribe, e-mail: users-unsubscribe_at_glassfish.dev.java.net
>> For additional commands, e-mail: users-help_at_glassfish.dev.java.net
>>
>>
>>
>