Re: [COMMITTERS] pgsql: Add sql_drop event for event triggers

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Dimitri Fontaine <dimitri(at)2ndquadrant(dot)fr>, Alvaro Herrera <alvherre(at)2ndquadrant(dot)com>, "pgsql-hackers(at)postgresql(dot)org" <pgsql-hackers(at)postgresql(dot)org>, pgsql-committers <pgsql-committers(at)postgresql(dot)org>
Subject: Re: [COMMITTERS] pgsql: Add sql_drop event for event triggers
Date: 2013-04-09 16:28:03
Message-ID: 3316.1365524883@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers pgsql-hackers

Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> I kind of wonder if there's some way we could split ProcessUtility()
> up into more digestible pieces. I can't really think of a good way to
> do it though, without writing duplicative switches.

I'm thinking a bit about

ProcessUtility()
{
switch (tag)
{
... cases for BEGIN etc ...
default:
ProcessSlowUtility(...)
}
}

ProcessSlowUtility()
{
event setup code
switch (tag)
{
... cases for everything else ...
default:
elog(ERROR)
}
event teardown code
}

regards, tom lane

In response to

Browse pgsql-committers by date

  From Date Subject
Next Message Tom Lane 2013-04-09 16:36:03 Re: [HACKERS] pgsql: Add sql_drop event for event triggers
Previous Message Dimitri Fontaine 2013-04-09 16:25:59 Re: [COMMITTERS] pgsql: Add sql_drop event for event triggers

Browse pgsql-hackers by date

  From Date Subject
Next Message Tom Lane 2013-04-09 16:36:03 Re: [HACKERS] pgsql: Add sql_drop event for event triggers
Previous Message Joshua D. Drake 2013-04-09 16:27:52 Re: page 1 of relation global/11787 was uninitialized