httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "David Burry" <>
Subject RE: Proposal: Header-size
Date Wed, 14 May 2003 08:12:59 GMT
If you only want a boolean confirmation of whether the request was
successful you might be able to use %c to get that effect, but if you
need real bytes for billing purposes or some other reason a count of
actual amount transferred you'd need to use mod_logio instead yes (which
is actually better for my example purpose since headers do cost on the

In principle I'm not against fixing %B/b to be like the old behavior or
adding a new header count value, because you can already get the value
from the Content-Length from %{Content-Length}o so no use in really
duplicating the same thing with using up one of those valuable single
letter values....  There was resistance to fixing %b/B to be like the
old behavior because it was supposedly very hard to do without redoing
the entire internal infrastructure or something...  If you can find a
way to do it anyway I'd be for keeping backward compatibility on
principle as well... ;o)


> -----Original Message-----
> From: Torbjörn Carlsson [] 
> Sent: Tuesday, May 13, 2003 7:16 AM
> To:
> Subject: Proposal: Header-size
> Hi.
> In the move from 1.3 to 2.0, a parameter in mod_log_config changed.
> %B/%b changed from bytes *really* sent to the same value as 
> the response-header 
> Content-Length, regardless of how much data that was actually 
> sent over the 
> wire. 
> I've seen comments on the list of the type "use mod_logio 
> instead", but 
> mod_logio is different in one aspect: It includes the header-size.
> In an unreliable network (read wireless or mobile) I need the 
> ability to 
> confirm that all data has been sent to the client.
> Because of the variable size of the response-header this is 
> not really possible 
> with mod_logio as is. The best I can get is an approximation. 
> "If %O > %B => Download probably OK"
> To fix this I've patched http_protocol to get the header-size 
> data, (See 
> included patch), to put the header-size in a note in the request_rec.
> This data can then be picked up in the log-module with %{Header-Size}n
> "%O - %{Header-Size}n => Bytes downloaded"
> Are there any problems with this patch, have I missed some 
> sideeffects, or is 
> it something that can be added to the source-tree, for 
> example to the mod_logio 
> instrumentation ?
> Regards
> /Torbjörn
> --
> Torbjörn Carlsson                               Mobility Partner AB
> email:    Box 1117, Kungsbron 21
> phone:  +46 730 40 68 10                        111 81 Stockholm

View raw message