Re: pgsql 7.2.3 crash

From: Joe Conway <mail(at)joeconway(dot)com>
To: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
Cc: Laurette Cisneros <laurette(at)nextbus(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: pgsql 7.2.3 crash
Date: 2002-10-13 05:31:31
Message-ID: 3DA90533.10900@joeconway.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Tom Lane wrote:
> Hackers: we might reasonably fix this by doing a deep copy of the
> relcache's trigger info during initResultRelInfo(); or we could fix it
> by getting rid of ri_TrigDesc and re-fetching from the relcache every
> time. The former would imply that trigger state would remain unchanged
> throughout a query, the latter would try to track currently-committed
> trigger behavior. Either way has got pitfalls I think.
>
> The fact that there's a problem at all is because people are using
> direct poking of the system catalogs instead of some kind of ALTER TABLE
> command to disable/enable triggers; an ALTER command would presumably
> gain exclusive lock on the table and thereby delay until active queries
> finish. But that technique is out there (even in pg_dump files :-() and
> so we'd best try to make the system proof against it.
>
> Any thoughts on which way to go?

I'd say:

1. go with the former
2. we definitely should also have an ALTER command to allow disable/enable of
triggers
3. along with the ALTER, document that directly messing with the system
catalogs is highly discouraged

Joe

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Barry Lind 2002-10-13 05:35:06 Re: [HACKERS] Difference between 7.2 and 7.3, possible bug?
Previous Message Tom Lane 2002-10-13 05:05:24 Re: [HACKERS] Difference between 7.2 and 7.3, possible bug?