Dominic Marks <[EMAIL PROTECTED]> > > http://www.acme.com/software/thttpd/notes.html on the section > regarding non-blocking I/O: > > "The fourth generation. One process only. No non-portable threads/LWPs. > Sends multiple files concurrently using non-blocking I/O, calling > select()/poll()/kqueue() to tell which ones are ready for more data. > Speed is excellent. Memory use is excellent. Portability is excellent. > Examples of this generation: Spinner, Open Market, and thttpd. Perhaps > Apache will switch to this method at some point. I really can't > understand why they went with that complicated pre-forking stuff. > Using non-blockijng I/O is just not that hard."
Apache-2.0 will use a combination of in-process threading and pre-forking by default, but the IO architecture has some scope for adding non-blocking IO in the future. The reasons for preforking are that it makes programming server extensions much easier, especially when you consider things like database libraries that don't provide a non-blocking API, etc. (Other bits of Apache are designed to be simple, like the memory management.) Another thing in preforking's favour is that it makes the server as a whole MUCH more robust -- a child process can blow up without taking down the server -- and again this has advantages with unreliable server extensions. Tony. To Unsubscribe: send mail to [EMAIL PROTECTED] with "unsubscribe freebsd-hackers" in the body of the message