Stas Bekman wrote:

Without trying to figure out why this happens, I can now see that it was clearly a mistake to expose this pool. Why? Because this pool is not thread-safe (remember it's a global static variable).

Well, I've figured it out anyway.

We have (t/conf/extra.conf.in):

<IfDefine PERL_USEITHREADS>
    PerlInterpStart         1
    PerlInterpMax           2
    PerlInterpMinSpare      1
    PerlInterpMaxSpare      2
</IfDefine>

So there could be only 2 perl interpreters at most used at any given time (talking about the main perl interpreters pool here). If the two are busy any new requests will block.

Now cleanup_register() ties a perl interpreter and doesn't release it until that cleanup handler is run. So that call:
$base_server_pool->cleanup_register(sub { Apache::OK });
was tieing an interpreter, but wasn't releasing it (since the pool is freed at the child_exit only). And therefore we had a lack of available interpreters and voilą the problem we had that we all saw.


I'll fix that shortly in the way suggested in my previous followup.

--
__________________________________________________________________
Stas Bekman            JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/     mod_perl Guide ---> http://perl.apache.org
mailto:[EMAIL PROTECTED] http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org   http://ticketmaster.com

---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]



Reply via email to