* dan nessett <[email protected]> [Fri, 14 Aug 2009 08:31:03 -0700 
(PDT)]:
> One of the first problems to solve in developing the proposed CPRT is
> how to call a function with the same name in two different MW
> distributions. I can think of 3 ways: 1) use the Namespace facility of
> PHP 5.3, 2) use threads, or 3) use separate process and IPC. Since 
MAMP
> supports none of these I am off building an AMP installation from
> scratch.
>
> Some questions:
>
> * Are there other ways to solve the identifier collision problem?
>
> * Are some of the options I mention unsuitable for a MW CPRT, e.g.,
> currently MW only assumes PHP 5.0 and requiring 5.3 may unacceptably
> constrain the user base.
>
> * Is MW thread safe?
>
I remember some time ago I was strongly discouraged to compile and run 
PHP threaded MPM for apache because some functions or libraries of PHP 
itself were not thread safe. Maybe that's changed recently, I don't know 
for sure. I think it would be simplier to run 2 Apaches listening to 
separate ports.
http://brian.moonspot.net/2008/02/13/apache-worker-and-php/
http://www.php.net/manual/en/faq.installation.php#faq.installation.apache2
" PHP is glue. It is the glue used to build cool web applications by 
sticking dozens of 3rd-party libraries together and making it all appear 
as one coherent entity through an intuitive and easy to learn language 
interface. The flexibility and power of PHP relies on the stability and 
robustness of the underlying platform. It needs a working OS, a working 
web server and working 3rd-party libraries to glue together. When any of 
these stop working PHP needs ways to identify the problems and fix them 
quickly. When you make the underlying framework more complex by not 
having completely separate execution threads, completely separate memory 
segments and a strong sandbox for each request to play in, feet of clay 
are introduced into PHP's system.

If you feel you have to use a threaded MPM, look at a FastCGI 
configuration where PHP is running in its own memory space.

And finally, this warning against using a threaded MPM is not as strong 
for Windows systems because most libraries on that platform tend to be 
threadsafe. "
Dmitriy

_______________________________________________
Wikitech-l mailing list
[email protected]
https://lists.wikimedia.org/mailman/listinfo/wikitech-l

Reply via email to