You are viewing a plain text version of this content. The canonical link for it is here.
Posted to modperl@perl.apache.org by Perrin Harkins <pe...@elem.com> on 2004/08/26 07:23:47 UTC
Re: [SITE][mp2] Associating an interpreter pool with a directory
rgies@copypasted.com wrote:
> Is it within the scope of mod_perl2 to duplicate its interpreter pool
> framework?
>
> Intention:
>
> To have separate interpreter pools for directories /test1 and /test2
Read http://perl.apache.org/docs/2.0/user/config/config.html
It looks like you would just need to do this:
<Location /test1>
PerlOptions +Clone
PerlInterpStart 2
PerlInterpMax 2
</Location>
<Location /test2>
PerlOptions +Clone
PerlInterpStart 2
PerlInterpMax 2
</Location>
You would have to run threads of course, e.g. the "worker" MPM. I run
in pre-fork MPM, so I haven't really played with these options yet.
> It is my current desire to go away from FastCGI and embrace mod_perl. For
> those familiar with FastCGI, I am wanting mod_perl2 to work the same way.
It doesn't sound that way to me. FastCGI does not support perl threads,
does it? The things you're talking about (only one singleton instance
per interpreter pool, global $count per pool) are only possible by using
perl threads.
- Perrin
--
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html
Re: [SITE][mp2] Associating an interpreter pool with a directory
Posted by Stas Bekman <st...@stason.org>.
Perrin Harkins wrote:
> On Thu, 2004-08-26 at 16:15, Stas Bekman wrote:
>
>>It works with prefork MPM too as long as perl has ithreads enabled, it's
>>exercised in the test suite.
>
>
> That wouldn't really be the same thing though, would it? For example,
> every child process would have a different $count variable and a
> different instance of the singleton object.
That's correct, Perrin.
--
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
--
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html
Re: [SITE][mp2] Associating an interpreter pool with a directory
Posted by Perrin Harkins <pe...@elem.com>.
On Thu, 2004-08-26 at 16:15, Stas Bekman wrote:
> It works with prefork MPM too as long as perl has ithreads enabled, it's
> exercised in the test suite.
That wouldn't really be the same thing though, would it? For example,
every child process would have a different $count variable and a
different instance of the singleton object.
- Perrin
--
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html
Re: [SITE][mp2] Associating an interpreter pool with a directory
Posted by Stas Bekman <st...@stason.org>.
Perrin Harkins wrote:
> rgies@copypasted.com wrote:
>
>> Is it within the scope of mod_perl2 to duplicate its interpreter pool
>> framework?
>>
>> Intention:
>>
>> To have separate interpreter pools for directories /test1 and /test2
>
>
> Read http://perl.apache.org/docs/2.0/user/config/config.html
>
> It looks like you would just need to do this:
>
> <Location /test1>
> PerlOptions +Clone
> PerlInterpStart 2
> PerlInterpMax 2
> </Location>
>
> <Location /test2>
> PerlOptions +Clone
> PerlInterpStart 2
> PerlInterpMax 2
> </Location>
>
> You would have to run threads of course, e.g. the "worker" MPM. I run
> in pre-fork MPM, so I haven't really played with these options yet.
It works with prefork MPM too as long as perl has ithreads enabled, it's
exercised in the test suite.
--
__________________________________________________________________
Stas Bekman JAm_pH ------> Just Another mod_perl Hacker
http://stason.org/ mod_perl Guide ---> http://perl.apache.org
mailto:stas@stason.org http://use.perl.org http://apacheweek.com
http://modperlbook.org http://apache.org http://ticketmaster.com
--
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html
Re: [SITE][mp2] Associating an interpreter pool with a directory
Posted by Jozef Kosoru <zy...@uid0.sk>.
On Thu, Aug 26, 2004 at 01:23:47 -0400, Perrin Harkins wrote:
> Read http://perl.apache.org/docs/2.0/user/config/config.html
>
> It looks like you would just need to do this:
>
> <Location /test1>
> PerlOptions +Clone
> PerlInterpStart 2
> PerlInterpMax 2
> </Location>
>
> <Location /test2>
> PerlOptions +Clone
> PerlInterpStart 2
> PerlInterpMax 2
> </Location>
>
> You would have to run threads of course, e.g. the "worker" MPM. I run
> in pre-fork MPM, so I haven't really played with these options yet.
Last time I tried "+Clone" option (approx. 1 month ago) it didn't work.
It caused Apache to hang on startup.
Does anybody successfully use this option?
jozef
--
jozef kosoru
http://zyzstar.kosoru.com
--
Report problems: http://perl.apache.org/bugs/
Mail list info: http://perl.apache.org/maillist/modperl.html
List etiquette: http://perl.apache.org/maillist/email-etiquette.html