Loading ...
Sorry, an error occurred while loading the content.
 

Re: get # of response bytes sent for large/streaming content?

Expand Messages
  • Jeff Ambrosino
    Yup, that works great. thanks! JB
    Message 1 of 3 , Sep 1, 2005
      Yup, that works great.

      thanks!
      JB


      On 9/1/05, Geoffrey Young <geoff@...> wrote:


      Jeff Ambrosino wrote:
      > I'm running a mod_perl cleanup handler from a reverse proxy
      > ($r->pool->cleanup_register), and
      > I need to know the total # of bytes sent in a response so I can store this
      > info in a database.
      > A real-world example would be the end user (browser) streaming a Quicktime
      > movie, and I want
      > to know how long this took, measured in bytes. Note the connection might be
      > aborted at any
      > time, so the number may vary. Apache already logs this info (transfer log),
      > so
      > it must be available, but how do I get at this information programmatically?

      the transfer log uses two methods, the first of which is private to apache
      but the other is $r->bytes_sent().  so, the numbers might differ a bit from
      the transfer log, but they ought to be close.

      HTH

      --Geoff

    Your message has been successfully submitted and would be delivered to recipients shortly.