From: Andres Freund <andres@anarazel.de>
To: Robert Haas <robertmhaas@gmail.com>
Cc: Craig Ringer <craig@postnewspapers.com.au>
Cc: Matthew Wakeling <matthew@flymine.org>
Cc: pgsql-performance@postgresql.org
Subject: Re: Pooling in Core WAS: Need help in performance tuning.
Date: Thu, 22 Jul 2010 23:29:54 +0200
Message-ID: <20100722212954.GA16758@anarazel.de> (raw)
In-Reply-To: <AANLkTikG_QqNXmGaAtnChGHyVAhdSosoE5M3MXwDKMH8@mail.gmail.com>
References: <4C37A9C1.1060405@2ndquadrant.com>
<4C37791C0200002500033379@gw.wicourts.gov>
<4C37CBFB.1000800@agliodbs.com>
<4C37EA1D.6000008@postnewspapers.com.au>
<AANLkTimNJZlX7kFH_r0-BB_K3NGorU7BHd85SxXJbuGJ@mail.gmail.com>
<4C38BF03.6060503@agliodbs.com>
<19244.1278787866@sss.pgh.pa.us>
<alpine.DEB.2.00.1007121044330.2534@aragorn.flymine.org>
<4C3AF564.5030204@postnewspapers.com.au>
<AANLkTikG_QqNXmGaAtnChGHyVAhdSosoE5M3MXwDKMH8@mail.gmail.com>
On Thu, Jul 22, 2010 at 02:33:43PM -0400, Robert Haas wrote:
> On Mon, Jul 12, 2010 at 6:58 AM, Craig Ringer
> <craig@postnewspapers.com.au> wrote:
> > On 12/07/10 17:45, Matthew Wakeling wrote:
> >>
> >> I'm surprised. Doesn't apache httpd do this? Does it have to do a whole
> >> load of non-portable stuff? It seems to work on a whole load of platforms.
> >
> > A lot of what Apache HTTPd does is handled via the Apache Portable
> > Runtime (APR). It contains a lot of per-platform handlers for various
> > functionality.
>
> Apache just has all of the worker processes call accept() on the
> socket, and whichever one the OS hands it off to gets the job.
As an inconsequential detail - afaik they keep the os from doing that
by protecting it with a mutex for various reasons (speed - as some
implementations wake up and see theres nothing to do, multiple
sockets, fairness)
> The problem is harder for us because a backend can't switch identities
> once it's been assigned to a database. I haven't heard an adequate
> explanation of why that couldn't be changed, though.
Possibly it might decrease the performance significantly enough by
reducing the cache locality (syscache, prepared plans)?
Andres
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients using the --to and --cc options:
reply via email
To: pgsql-performance@postgresql.org
Cc: andres@anarazel.de, robertmhaas@gmail.com, craig@postnewspapers.com.au, matthew@flymine.org
Subject: Re: Pooling in Core WAS: Need help in performance tuning.
In-Reply-To: <20100722212954.GA16758@anarazel.de>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox