Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 15 Jul 1999 12:35:00 -0700 (PDT)
From:      Tani Hosokawa <unknown@riverstyx.net>
To:        David Schwartz <davids@webmaster.com>
Cc:        lh@aus.org, chat@FreeBSD.ORG
Subject:   RE: Known MMAP() race conditions ... ?
Message-ID:  <Pine.LNX.4.10.9907151216050.10288-100000@avarice.riverstyx.net>
In-Reply-To: <000001becef6$6853c670$021d85d1@youwant.to>

next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 15 Jul 1999, David Schwartz wrote:

> > 	It's one-process-per-request model is atrocious.
> 
> 	Let me retract this statement, because it's not really fair.
> 
> 	Apache has done an amazing job of getting very good performance on a wide
> variety of platforms. The one-process-per-request model does create
> problems, but they're usually in special cases, like when you're using lots
> of perl CGIs and mod_perl.

If you're just talking about the big fat memory footprints, you can do
what the performance tuning guide suggests and put a proxy (like Squid) in
front of it.  I'm using mod_perl to serve a similar amount of requests I'd
be able to do with static data.

You've also brought up another good point -- portability between platforms
can be increased by using a good threading model.  Like, with the apr
project.  And it's easier to code for.  Time to market is a major factor
in a lot of decisions, and if it's going to be harder to code for X
platform because it doesn't support the easiest model well, then it might
be better to go with Y platform that has some disadvantages comparitively,
but kicks ass on the issue that's being addressed.

> 	But if you're going to change it, and lose that, you should change it in
> favor of a clearly better model. And I'm not sure one-thread-per-request is
> clearly better.

Per-thread is clearly better, for a number of reasons.

 o shared address space being one of them
 o better caching of the filesystem
 o context switches between threads are generally less expensive than
   context switches between processes
 o easy upgrade path from per-process to per-thread for user modules

---
tani hosokawa
river styx internet




To Unsubscribe: send mail to majordomo@FreeBSD.org
with "unsubscribe freebsd-chat" in the body of the message




Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.LNX.4.10.9907151216050.10288-100000>