Re: procpid? - Mailing list pgsql-hackers

From Tom Lane
Subject Re: procpid?
Date
Msg-id 29136.1308152423@sss.pgh.pa.us
Whole thread Raw
In response to Re: procpid?  (Gurjeet Singh <singh.gurjeet@gmail.com>)
List pgsql-hackers
Gurjeet Singh <singh.gurjeet@gmail.com> writes:
> On Wed, Jun 15, 2011 at 10:31 AM, Robert Haas <robertmhaas@gmail.com> wrote:
>> Well, that would probably be a lot slower, and wouldn't necessarily
>> deliver as consistent a snapshot of system activity.  It's better to
>> have one set-returning function that dumps out all the data in a
>> single pass.

> I wanted to address consistency issue in the previous mail, but then wanted
> that to be left for later.

> We can provide consistency the same way pg_locks provides; take a snapshot
> on first request within a transaction, and reuse that snapshot for
> subsequent calls. In this case we might want to go a bit finer grained by
> providing a snapshot for every query.

Quite honestly, the implementation mechanism used by the other
statistics views is enormous overkill.  I agree with Robert that I'm not
eager to duplicate that for the activity view, when a simple SRF can get
the job done.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Gurjeet Singh
Date:
Subject: Re: procpid?
Next
From: Tom Lane
Date:
Subject: Re: FK NOT VALID can't be deferrable?