Re: Table rewrites vs. pending AFTER triggers

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Table rewrites vs. pending AFTER triggers
Дата
Msg-id 5721.1199374852@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Table rewrites vs. pending AFTER triggers  (Alvaro Herrera <alvherre@commandprompt.com>)
Ответы Re: Table rewrites vs. pending AFTER triggers  (Andrew Dunstan <andrew@dunslane.net>)
Список pgsql-hackers
Alvaro Herrera <alvherre@commandprompt.com> writes:
>> On Tue, 2008-01-01 at 16:09 -0500, Tom Lane wrote:
>>> Paranoia would
>>> suggest forbidding *any* form of ALTER TABLE when there are pending
>>> trigger events, but maybe that's unnecessarily strong.

> I disagree.  This is an implementation limitation, so it makes sense to
> try to restrict the user as least as possible.

There's a tradeoff here between security, flexibility, and the amount of
work we want to put into it.  At the moment it's not clear to me that
it's worth spending the amount of work that would be needed to determine
which forms of ALTER TABLE are "safe" in this connection.  If you're
feeling hot about it, feel free to do the legwork.

(A precedent is that all forms of ALTER TABLE take exclusive lock,
which is more or less the same thing for the cross-backend case.
There's been occasional discussion of whether some forms could
take lesser locks, but never enough interest to make it happen.)
        regards, tom lane


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

Предыдущее
От: Peter Eisentraut
Дата:
Сообщение: Re: Selectivity estimation for equality and range queries
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Selectivity estimation for equality and range queries