perl-modperl mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Stas Bekman <>
Subject Re: bytes_received?
Date Thu, 09 Dec 2004 19:46:54 GMT
Malcolm J Harwood wrote:
> Is there an equivalent of Apache::RequestRec::bytes_sent for the size of the 
> incoming request? (I have a situation where I need to log the size of the 
> data transfer each way to a db). I've searched through the docs (and google) 
> and not found anything.

> The closest I've found to getting this is "length $r->as_string;" which is 
> ugly and likely very inefficient. Is there a better way? 

$ENV{CONTENT_LENGTH} or $r->headers_in->{CONTENT_LENGTH}? Of course it's 
not guaranteed that it'll be set.

Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker     mod_perl Guide --->

Report problems:
Mail list info:
List etiquette:

View raw message