From: Tom Lane <tgl@sss.pgh.pa.us>
To: Andres Freund <andres@2ndquadrant.com>
Cc: Dimitri Fontaine <dimitri@2ndQuadrant.fr>
Cc: Simon Riggs <simon@2ndquadrant.com>
Cc: Robert Haas <robertmhaas@gmail.com>
Cc: Alvaro Herrera <alvherre@2ndquadrant.com>
Cc: PostgreSQL Hackers <pgsql-hackers@postgresql.org>
Subject: Re: Event Triggers: adding information
Date: Thu, 17 Jan 2013 22:14:04 -0500
Message-ID: <24062.1358478844@sss.pgh.pa.us> (raw)
In-Reply-To: <20130118030124.GI3074@awork2.anarazel.de>
References: <CA+TgmobfeB_YpgMv5NjW52tG36Hg_DY=jq0XDkE5zwCstPQ4pg@mail.gmail.com>
<m2pq14m7sx.fsf@2ndQuadrant.fr>
<CA+TgmoYEW583z+oisToCYQMz2grzpavdXrCi3-W2D_+nucVhzQ@mail.gmail.com>
<CA+U5nM+Uuh7cyHSJ5wN54twBUGSncJzqpZB83xuZw4VP7UCziQ@mail.gmail.com>
<16675.1358454278@sss.pgh.pa.us>
<m2hamfcwc8.fsf@2ndQuadrant.fr>
<18941.1358462151@sss.pgh.pa.us>
<m2ehhjbf48.fsf@2ndQuadrant.fr>
<20130118013334.GE3074@awork2.anarazel.de>
<23579.1358477281@sss.pgh.pa.us>
<20130118030124.GI3074@awork2.anarazel.de>
List-Unsubscribe: <mailto:majordomo@postgresql.org?body=unsub%20pgsql-hackers>
Andres Freund <andres@2ndquadrant.com> writes:
> On 2013-01-17 21:48:01 -0500, Tom Lane wrote:
>> If we're only interested in replication, let's put in some hooks whose
>> contract does not allow for side-effects on the local catalogs, and be
>> done. Otherwise we'll be putting in man-years of unnecessary (or at
>> least unnecessary for this use-case) work.
> Its a thing of perspective I guess. I can't imagine a hook-ey solution,
> without quite a bit of work, that gets enough information to regenerate
> SQL that performs the same action on another system. ISTM that the
> refactoring to make that consistently "easy" is the hard part, but I
> hope I am wrong.
The problem of how to get the information needed is real and large,
I agree. But that's not any easier for a trigger --- if anything,
it's probably harder, because then you not only need to *get* the
information but you have to figure out how to provide it in a way
that makes sense at SQL level.
regards, tom lane
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers
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-hackers@postgresql.org
Cc: tgl@sss.pgh.pa.us, andres@2ndquadrant.com, dimitri@2ndQuadrant.fr, simon@2ndquadrant.com, robertmhaas@gmail.com, alvherre@2ndquadrant.com
Subject: Re: Event Triggers: adding information
In-Reply-To: <24062.1358478844@sss.pgh.pa.us>
* 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