From: | Russell Smith <mr-russ(at)pws(dot)com(dot)au> |
---|---|
To: | Christopher Kings-Lynne <chriskl(at)familyhealth(dot)com(dot)au> |
Cc: | Neil Conway <neilc(at)samurai(dot)com>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: locks in CREATE TRIGGER, ADD FK |
Date: | 2005-03-23 02:37:59 |
Message-ID: | 200503231337.59881.mr-russ@pws.com.au |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Wed, 23 Mar 2005 12:40 pm, Christopher Kings-Lynne wrote:
> If you want to be my friend forever, then fix CLUSTER so that it uses
> sharerowexclusive as well :D
>
I don't think it's as easy as that, because you have to move tuples
around in the cluster operation. Same sort of issue as vacuum full I would suggest.
Russell Smith
> Chris
>
> Neil Conway wrote:
> > Neil Conway wrote:
> >
> >> AndrewSN pointed out on IRC that ALTER TABLE ... ADD FOREIGN KEY and
> >> CREATE TRIGGER both acquire AccessExclusiveLocks on the table they are
> >> adding triggers to (the PK table, in the case of ALTER TABLE). Is this
> >> necessary? I don't see why we can't allow SELECT queries on the table
> >> to proceed while the trigger is being added.
> >
> >
> > Attached is a patch that changes both to use ShareRowExclusiveLock, and
> > updates the documentation accordingly. I'll apply this later today,
> > barring any objections.
>
> ---------------------------(end of broadcast)---------------------------
> TIP 1: subscribe and unsubscribe commands go to majordomo(at)postgresql(dot)org
>
>
From | Date | Subject | |
---|---|---|---|
Next Message | Bruce Momjian | 2005-03-23 02:41:48 | Re: psql and pg_dump using obselete copy commands |
Previous Message | Bruce Momjian | 2005-03-23 02:37:19 | Re: Using new copy libpq functions on a v2 protocol backend |