Re: Patch: plan invalidation vs stored procedures

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Patch: plan invalidation vs stored procedures
Дата
Msg-id 28763.1219241903@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Patch: plan invalidation vs stored procedures  (Alvaro Herrera <alvherre@commandprompt.com>)
Ответы Re: Patch: plan invalidation vs stored procedures  (Decibel! <decibel@decibel.org>)
Список pgsql-hackers
Alvaro Herrera <alvherre@commandprompt.com> writes:
> This is where the interesting questions are:
> http://archives.postgresql.org/message-id/10333.1219179364%40sss.pgh.pa.us

Upthread, someone speculated about solving the problem by forcing plan
cache flush on *any* catalog change.  I think that's probably not
acceptable from an efficiency standpoint.  But maybe it'd be a good idea
to special-case common cases and fall back to a stupid flush for less
common cases, rather than invest all the work that'd be needed to track
every direct and indirect dependency of every plan.  My first thought
along these lines is:

* track table dependencies exactly (important for efficiency, plus we've got the code already)

* track function dependencies exactly (seems function definitions might change often enough to make it important for
efficiency;maybe only track PL function dependencies??)
 

* brute-force flush for any other catalog change that could affect plans

However I have no hard evidence to back up drawing the line there rather
than somewhere else.  Anyone have data on what sort of DDL changes are
common in their applications?
        regards, tom lane


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

Предыдущее
От: Alvaro Herrera
Дата:
Сообщение: make dist does not work in VPATH
Следующее
От: Tom Lane
Дата:
Сообщение: Re: Volatile functions in subqueries don't prevent subqueries from being evaluated in initplans?