httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From James Sutherland <>
Subject Re: Logging aborted connections in the access log
Date Thu, 07 Sep 2000 15:01:11 GMT
On Thu, 7 Sep 2000, Bill Stoddard wrote:

> It would be useful to note in the access log when a request has been
> aborted by the client.  The condition is easy to detect in
> mod_log_config by checking r->connection->aborted.  I've considered
> several ways to log the info, none of which are particularly
> appealing:
> 1. Introduce a new LogFormat formatting field, %c, which would spit out a
> suitable indicator. " X" if the connection was aborted, "-" otherwise.

Good idea.

> 2. Tweaking the behavious of the %s format field (%s displays the
> response status) thusly..  200 ==> good response, 200x ==> Good
> response, but the client closed the connection before the response
> could be forwarded. I think this would break log analysis tools that
> depend on the status field being three digits, so probably not a good
> idea.

Eurgh! Yep, that would break everything... I have this strange belief that
the status code logged should be the status code :-)

> 3. Tweaking the behavious of the %s format field thusly... 200 ==>
> good response, 499 ==> client closed the connection. This has two
> problems, first is 499 is not an official client error code. Second,
> we loose the original response status.  I tend to like this one the
> best though. Perhaps we should create a new client error code to show
> this condition?

Eurgh... Also nasty... If we send the client a 20x response, and the
connection is broken part-way, I want to see a 20x response logged!

I'd prefer option 1. Off-hand, I can't think of any way to change another
field to indicate this without risking some breakage...


View raw message