I don't understand the question.  You can use a multithreaded library with 
PHP if you want.  That doesn't have anything to do with Apache being
threaded.  Or do you mean that the library is guaranteed to be threadsafe?  
If so, you may be ok, but you have to be sure that every other library 
involved is also threadsafe.  Chances are they aren't, and even if they 
magically are you better hope you never run into any sort of weird 
problem, because if you do you will never know if it was caused by a 
virtually impossible to debug race condition in any of the dozens of 
libraries involved or not.

A threaded web server behind a general-purpose scripting language like 
Perl or PHP simply makes no sense to me.  You want a robust and simple 
base platform to layer your application on top of.  We humans are not 
smart enough, nor do we have the tools, to build and debug large threaded 
applications.

Note also that most developers who tell you their code is threadsafe don't 
really know if that is true.  All code relies on external things that may 
or may not be threadsafe and we don't have any tools to verify claims of 
thread safety.

-Rasmus

On Mon, 2 Feb 2004, ashish b\ wrote:

> what if i am loading a library which is multithreaded?
> 
> Rasmus Lerdorf <[EMAIL PROTECTED]> wrote:Yup
> 
> On Mon, 2 Feb 2004, ashish b\ wrote:
> 
> > hello ,
> > is compiling Apache in worker mode really unstable for production purposes?
> > Is multithreaded mode of apache really unsafe?
> > 
> > Doumentation of PHP says 
> > In case you wish to build a multithreaded version of Apache 2.0 you must overwrite 
> > the standard MPM-Module prefork either with worker or perchild. To do so append to 
> > your configure line either the option --with-mpm=worker or --with-mpm=perchild. 
> > Take care about the consequences and understand what you are doing. For more 
> > information read the Apache documentation about the MPM-Modules. 
> > 
> > Note: To build a multithreaded version of Apache your system must support threads. 
> > This also implies to build PHP with experimental Zend Thread Safety (ZTS). 
> > Therefore not all extensions might be available. The recommended setup is to build 
> > Apache with the standard prefork MPM-Module. 
> > 
> > 
> > 
> > 
> > 
> > ---------------------------------
> > Do you Yahoo!?
> > Yahoo! SiteBuilder - Free web site building tool. Try it!
> 
> -- 
> PHP Internals - PHP Runtime Development Mailing List
> To unsubscribe, visit: http://www.php.net/unsub.php
> 
> 
> 
> ---------------------------------
> Do you Yahoo!?
> Yahoo! SiteBuilder - Free web site building tool. Try it!

-- 
PHP Internals - PHP Runtime Development Mailing List
To unsubscribe, visit: http://www.php.net/unsub.php

Reply via email to