Re: Reduce lock levels others reloptions in ALTER TABLE - Mailing list pgsql-hackers

From Robert Haas
Subject Re: Reduce lock levels others reloptions in ALTER TABLE
Date
Msg-id CA+TgmoZSn+=ewPE2yTuBYzCF-HZcScc=KL9dbs1Ueb3S7vBA8A@mail.gmail.com
Whole thread Raw
In response to Reduce lock levels others reloptions in ALTER TABLE  (Fabrízio de Royes Mello <fabriziomello@gmail.com>)
Responses Re: Reduce lock levels others reloptions in ALTER TABLE  (Simon Riggs <simon@2ndQuadrant.com>)
List pgsql-hackers
On Mon, Feb 29, 2016 at 12:58 PM, Fabrízio de Royes Mello
<fabriziomello@gmail.com> wrote:
> Some time ago we added [1] the infrastructure to allow different lock levels
> for relation options.
>
> So per discussion [2] the attached patch reduce lock levels down to
> ShareUpdateExclusiveLock for:
> - fastupdate
> - fillfactor
> - gin_pending_list_limit
> - seq_page_cost
> - random_page_cost
> - n_distinct
> - n_distinct_inherited
> - buffering

I am of the opinion that there needs to be comments or a README or
some kind of documentation somewhere indicating the rationale for the
lock levels we choose here.  Just changing it without analyzing why a
certain level is sufficient for safety and no higher than necessary
seems poor.  And the reasoning should be documented for future
readers.

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company



pgsql-hackers by date:

Previous
From: Petr Jelinek
Date:
Subject: Re: The plan for FDW-based sharding
Next
From: Bruce Momjian
Date:
Subject: Re: The plan for FDW-based sharding