Re: logging in high performance systems.

From: Alvaro Herrera <alvherre(at)commandprompt(dot)com>
To: Marti Raudsepp <marti(at)juffo(dot)org>
Cc: Theo Schlossnagle <jesus(at)omniti(dot)com>, Pg Hackers <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: logging in high performance systems.
Date: 2012-01-17 16:54:49
Message-ID: 1326819124-sup-2856@alvh.no-ip.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers


Excerpts from Marti Raudsepp's message of mar ene 17 12:12:50 -0300 2012:
> On Thu, Nov 24, 2011 at 04:28, Theo Schlossnagle <jesus(at)omniti(dot)com> wrote:
> > So... here's my first whack at solving this with some flexibility.
> >
> > The first thing I did was add hook points where immediate statement
> > logging happens "pre_exec" and those that present duration
> > "post_exec".  These should, with optimization turned on, have only a
> > few instructions of impact when no hooks are registered (we could
> > hoist the branch outside the function call if that were identified as
> > an issue).
>
> Note that the hook mechanism you've built is a departure from how
> other hooks are managed in Postgres. Traditionally hooks are just
> global function pointers, and each consumer is responsible for storing
> the previous value of the hook and chain-calling it in the handler. If
> you want to change this pattern, I think you should start another
> discussion.

Hm. We already have places doing the other thing, for example
see XactCallback and ExprContextCallback. Not sure we have an actual
criteria for deciding when to use which.

--
Álvaro Herrera <alvherre(at)commandprompt(dot)com>
The PostgreSQL Company - Command Prompt, Inc.
PostgreSQL Replication, Consulting, Custom Development, 24x7 support

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Peter Eisentraut 2012-01-17 16:59:57 how to create a non-inherited CHECK constraint in CREATE TABLE
Previous Message Alvaro Herrera 2012-01-17 16:50:41 Re: automating CF submissions (was xlog location arithmetic)