>
>
> $request++;
>
> That's what I do in some handler, and then I log it along with the PID.

Eh?  I'm confused.  What is '$request' in that example?  If you
mean it's the request object, then that doesn't do what I expect.

This code:

warn "request is [".$r."]\n";

yields:

request is [Apache::Request=SCALAR(0x862a9ec)]

I am pretty sure what he is proposing as a solution (something which I have also done):


Set a normal var to 0 (say in a PerlChildInitHandler)
Then in the PerlHandler increment the normal var

$phase = $r->current_callback;

if ($phase eq 'PerlChildInitHandler')
{
   $reqCtr = 0;
}

if ($phase eq 'PerlHandler')
{
   $reqCtr++;
}

Or, you could use a note and skip the global scalar.

I don't think mod_perl has direct access to the current count (at least not in mp1).

Matt









Reply via email to