Re: [HACKERS] Reduce lock levels for reloptions

2017-02-26 Thread Robert Haas
On Sat, Feb 25, 2017 at 11:24 PM, Simon Riggs  wrote:
> Patch to reduce lock levels of various relation-level options,
> following on from earlier work by Fabrizio, with additional work and
> documentation by me.

I have reviewed this patch and I think it looks reasonable.  I think
that the behavior will be that overlapping transactions may or may not
pick up the new values depending on whether they already have a lock
on the relation and whether they happen to have a relcache flush for
some other reason, but new transactions started after the value is
altered via DDL should always see the new value, because they will
always do AcceptInvalidationMessages() after locking the relation, and
if they haven't yet picked up the value by that point, then they will
see it then.  If that sounds right, maybe we should document someplace
in the SGML documentation that new values of reloptions which can be
changed without AEL might or might not be seen by overlapping
transactions; perhaps the lock levels for each reloption should also
be documented (since, as evidenced by this and previous patches,
people obviously do care about what those levels are).

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


-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers


[HACKERS] Reduce lock levels for reloptions

2017-02-25 Thread Simon Riggs
Patch to reduce lock levels of various relation-level options,
following on from earlier work by Fabrizio, with additional work and
documentation by me.

Submitted to Sept CF, requested to start new thread to discuss
https://www.postgresql.org/message-id/CA%2BTgmoYe5eDhjRodo3uOtVFGiDWwO2zGUp_mDHeSxuEqq-jS_A%40mail.gmail.com

Earlier patch, dropped from 9.6
https://www.postgresql.org/message-id/CANP8%2Bj%2B0fuq2MWKvUsQTJFt8EF_z-Tyn-Q61J2A%2BVT2Uzuf-Rg%40mail.gmail.com

-- 
Simon Riggshttp://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services


reduce_lock_levels_incl_comments.v2.patch
Description: Binary data

-- 
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers