Re: Broken lock management in policy.c.

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Broken lock management in policy.c.
Дата
Msg-id 22458.1451872490@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Broken lock management in policy.c.  (Stephen Frost <sfrost@snowman.net>)
Список pgsql-hackers
Stephen Frost <sfrost@snowman.net> writes:
> On Sunday, January 3, 2016, Tom Lane <tgl@sss.pgh.pa.us> wrote:
>> CREATE POLICY takes AccessExclusiveLock on the table a policy is being
>> added to -- good -- and then releases it when done -- bad.  Correct
>> behavior is to hold the lock till commit, because otherwise there is
>> no guarantee that other backends will see the updated catalog rows in
>> time, or indeed at all.

> Agreed.

On closer inspection, I'd misidentified the functions containing the
bad code --- it was really RemovePolicyById and RemoveRoleFromObjectPolicy
that were wrong.  Fix pushed.
        regards, tom lane



В списке pgsql-hackers по дате отправления:

Предыдущее
От: Jim Nasby
Дата:
Сообщение: 9.5 BLOCKER: regrole and regnamespace and quotes
Следующее
От: Peter Geoghegan
Дата:
Сообщение: Re: Broken lock management in policy.c.