Re: ALTER TABLE SET STATISTICS requires AccessExclusiveLock

From: Simon Riggs <simon(at)2ndQuadrant(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Andres Freund <andres(at)anarazel(dot)de>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: ALTER TABLE SET STATISTICS requires AccessExclusiveLock
Date: 2010-07-19 06:46:52
Message-ID: 1279522012.25158.10782.camel@ebony
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Sun, 2010-07-18 at 22:47 -0400, Robert Haas wrote:
> But it seems
> that it's far from clear what to do about it, and it's not the job of
> this patch to fix it anyway.

Agreed.

> Regarding the actual patch, it looks mostly good. Questions:
>
> 1. Why in rewriteSupport.c are we adding a call to
> heap_inplace_update() in some situations? Doesn't seem like this is
> something we should need or want to be monkeying with.

Hmm, yes, that looks like a hangover. Will change. No others similar.

> 2. Instead of AlterTableGreatestLockLevel(), how about
> AlterTableGetLockLevel()? Yeah, it's going to be the highest lock
> level required by any subcommand, but it seems mildly overspecified.
> I don't feel strongly about this one, though, if someone has a strong
> contrary opinion...

I felt it indicated the process it's using. Happy to change.

--
Simon Riggs www.2ndQuadrant.com
PostgreSQL Development, 24x7 Support, Training and Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Artur Dabrowski 2010-07-19 09:50:50 Re: Incorrect FTS result with GIN index
Previous Message Bruce Momjian 2010-07-19 05:02:08 Re: crash-recovery replay of CREATE TABLESPACE is broken in HEAD