Re: ERROR: tuple concurrently updated when modifying privileges

2019-05-14 Thread Chris Travers
On Tue, May 14, 2019 at 9:11 AM Michael Paquier wrote: > On Tue, May 14, 2019 at 08:08:05AM +0200, Chris Travers wrote: > > Having thought about this a bit, I think the best solution would be to > have > > grant take out an access share lock to the tables granted. This would > > prevent concurre

Re: ERROR: tuple concurrently updated when modifying privileges

2019-05-14 Thread Michael Paquier
On Tue, May 14, 2019 at 08:08:05AM +0200, Chris Travers wrote: > Having thought about this a bit, I think the best solution would be to have > grant take out an access share lock to the tables granted. This would > prevent concurrent alter table operations from altering the schema > underneath the

Re: ERROR: tuple concurrently updated when modifying privileges

2019-05-13 Thread Chris Travers
On Tue, Apr 30, 2019 at 11:26 AM nickb wrote: > Hello, hackers > > we witnessed this slightly misleading error in production and it took us a > while to figure out what was taking place. > Below are reproduction steps: > > > -- setup > create table trun(cate int4); > > -- session 1 > begin; > tru

ERROR: tuple concurrently updated when modifying privileges

2019-04-30 Thread nickb
Hello, hackers we witnessed this slightly misleading error in production and it took us a while to figure out what was taking place. Below are reproduction steps: -- setup create table trun(cate int4); -- session 1 begin; truncate table trun; -- session 2 grant insert on table trun to postgre