Re: ALTER TABLE lock strength reduction patch is unsafe - Mailing list pgsql-hackers

From Robert Haas
Subject Re: ALTER TABLE lock strength reduction patch is unsafe
Date
Msg-id CA+Tgmob8cu_886p1h0ukknNVyiqnt=3EQWdt+C1uchfHUZqjig@mail.gmail.com
Whole thread Raw
In response to Re: ALTER TABLE lock strength reduction patch is unsafe  (Simon Riggs <simon@2ndQuadrant.com>)
Responses Re: ALTER TABLE lock strength reduction patch is unsafe
Re: ALTER TABLE lock strength reduction patch is unsafe
List pgsql-hackers
On Thu, Feb 27, 2014 at 3:12 AM, Simon Riggs <simon@2ndquadrant.com> wrote:
> Removing SELECT privilege while running a SELECT would be a different
> matter.  This is all a matter of definition; we can make up any rules
> we like. Doing so is IMHO a separate patch and not something to hold
> up the main patch.

So I think this is an interesting point.  There are various things
that could go wrong as a result of using the wrong lock level.  Worst
would be that the server crashes or corrupts data.  A little less bad
would be that sessions error out with inexplicable error conditions,
as in SnapshotNow days.  Alternatively, we could just have arguably
wrong behavior, like basing query results on the old version of the
table's metadata even after it's been changed.

I don't really care about that second category of behavior.  If
somebody changes some property of a table and existing sessions
continue to use the old value until eoxact, well, we can argue about
that, but at least until we have concrete reports of really
undesirable behavior, I don't think it's the primary issue.  What I'm
really concerned about is whether there are other things like the
SnapshotNow issues that can cause stuff to halt and catch fire.  I
don't know whether there are or are not, but that's my concern.

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



pgsql-hackers by date:

Previous
From: Oleg Bartunov
Date:
Subject: Re: jsonb and nested hstore
Next
From: Andres Freund
Date:
Subject: Re: jsonb and nested hstore