Re: [COMMITTERS] pgsql: Teach tuplesort.c about "top N" sorting, in which only the first

From: Magnus Hagander <magnus(at)hagander(dot)net>
To: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
Cc: Jim Nasby <decibel(at)decibel(dot)org>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: [COMMITTERS] pgsql: Teach tuplesort.c about "top N" sorting, in which only the first
Date: 2007-05-08 19:24:19
Message-ID: 4640CE63.2010900@hagander.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

Magnus Hagander wrote:
> Alvaro Herrera wrote:
>> Jim Nasby wrote:
>>
>>> If we really want to make the logfile the approved method for
>>> monitoring performance, then why do we have the stats infrastructure
>>> at all? It could all be replaced with logging output and pgfouine.
>> First we'd have to fix the usability problem of our redirect_stderr
>> stuff for pgfouine (multiline messages from different backends are
>> mixed, according to Guillaume).
>
> I'd like to sign on to the list of people saying that logging isn't the
> best way to do performance measuring. Providing a way to get at the
> counters in realtime for monitoring or graphing or whatever is what
> AFAIK everybody else do, and it's for a good reason - it fits in to
> existing monitoring/management solutions. It may be that our current
> stats system isn't the best way to do this, but if it isn't that just
> means we have to come up with a better way.

Speaking of which, it might be interesting to actually show these values
in the stats collector. I was thinking three cols for each database
(probably the best level?) that counts each of those three counters. If
you have a lot of sorts (percentage-wise) spilling to disk, it is often
something you want to investigate, so exposing it that way seems like a
good thing.

Comments on that? Oh, and is it too late to sneak this into 8.3 claiming
it's an extension to the addition of the new sort feature? ;-)

//Magnus

In response to

Responses

Browse pgsql-committers by date

  From Date Subject
Next Message Hiroshi Inoue 2007-05-08 21:32:35 Re: [COMMITTERS] psqlodbc - psqlodbc: Put Autotools-generated files into subdirectory
Previous Message Tom Lane 2007-05-08 19:13:52 pgsql: Reserve some pg_statistic "kind" codes for use by the ESRI

Browse pgsql-hackers by date

  From Date Subject
Next Message Lukas Kahwe Smith 2007-05-08 19:32:33 Re: Managing the community information stream
Previous Message Tom Lane 2007-05-08 19:16:16 Re: Patch: Allocation of "kind" codes for spatial type.