Re: Improve behavior of concurrent ANALYZE/VACUUM

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: Improve behavior of concurrent ANALYZE/VACUUM
Дата
Msg-id 20180817064223.GH1693@paquier.xyz
обсуждение исходный текст
Ответ на Improve behavior of concurrent ANALYZE/VACUUM  (Michael Paquier <michael@paquier.xyz>)
Ответы Re: Improve behavior of concurrent ANALYZE/VACUUM  ("Bossart, Nathan" <bossartn@amazon.com>)
Список pgsql-hackers
On Mon, Aug 13, 2018 at 12:21:42AM +0200, Michael Paquier wrote:
> The patch attached includes tests which I have used to also check that
> correct error messages are produced for VACUUM, VACUUM ANALYZE and
> ANALYZE.

I have reworked the patch on this side, clarifying the use of the new
common API for the logs.  One thing I am wondering about is what do we
want to do when VACUUM ANALYZE is used.  As of HEAD, if vacuum_rel()
stops, then analyze_rel() is never called, and the only log showing up
to a non-owner user would be:
skipping "foo" --- only superuser can vacuum it

With this patch, things become perhaps more confusing by generating two
WARNING log entries:
skipping "foo" --- only superuser can vacuum it
skipping "foo" --- only superuser can analyze it

We could either combine both in a single message, or just generate the
message for vacuum as HEAD does now.  I have also added some simple
regression tests triggering the skipping logs for shared catalogs,
non-shared catalogs and non-owners.  This could be a separate patch as
well.

Input is welcome.
--
Michael

Вложения

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

Предыдущее
От: Ashutosh Bapat
Дата:
Сообщение: Re: TupleTableSlot abstraction
Следующее
От: David Rowley
Дата:
Сообщение: Re: FailedAssertion on partprune