Re: event trigger API documentation?

From: Dimitri Fontaine <dimitri(at)2ndQuadrant(dot)fr>
To: Peter Eisentraut <peter_e(at)gmx(dot)net>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, "pgsql-hackers\(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: event trigger API documentation?
Date: 2013-04-18 09:05:15
Message-ID: m238uonr90.fsf@2ndQuadrant.fr
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Peter Eisentraut <peter_e(at)gmx(dot)net> writes:
> Offhand, that seems about enough, but I'm just beginning to explore.

I'm interested into hearing about any such use case…

> Chances are, event triggers will end up somewhere near the top of the
> release announcements, so we should have a consistent message about what
> to do with them and how to use them. If for now, we say, we only
> support writing them in PL/pgSQL, and here is how to do that, and here
> are some examples, that's fine. But currently, it's not quite clear.

I would prefer that we're silent about them for another (couple of?)
release, because we didn't reach yet the feature set that I did consider
the bare minimum. In my view 9.3 only has code infrastructure to prepare
for the ability to implement Event Triggers later. That this
infrastructure already allows you to do some things with it is like a
proof of concept.

> Surely you had some use cases in mind when you set out to implement
> this. What were they, and where are we now in relation to them?

I have mainly 4 use cases for them, and none of them are possible to
implement in 9.3:

- audit (separate log or audit tables for commited only actions)
- ddl support for replications (trigger based, logical rep.)
- ddl extensibility
- apt-get for extensions without dynamically loaded module

The extension items is an example of the more general "ddl
extensibility" item. Don't worry about ever seeing a patch to core for
implementing it, the whole Event Trigger and Extension Templates
exercise is meant to allow for coding that kind of crazy ideas out of
core.

Regards,
--
Dimitri Fontaine
http://2ndQuadrant.fr PostgreSQL : Expertise, Formation et Support

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Daniel Farina 2013-04-18 10:43:43 Re: Enabling Checksums
Previous Message Simon Riggs 2013-04-18 08:17:39 Re: Enabling Checksums