Re: [PATCH] Disable bgworkers during servers start in pg_upgrade

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [PATCH] Disable bgworkers during servers start in pg_upgrade
Дата
Msg-id YShtA86sOfazb9at@paquier.xyz
обсуждение исходный текст
Ответ на Re: [PATCH] Disable bgworkers during servers start in pg_upgrade  (Julien Rouhaud <rjuju123@gmail.com>)
Ответы Re: [PATCH] Disable bgworkers during servers start in pg_upgrade  (Julien Rouhaud <rjuju123@gmail.com>)
Список pgsql-hackers
On Fri, Aug 27, 2021 at 11:25:19AM +0800, Julien Rouhaud wrote:
> Right now AFAICT there's no official API to check if a call to
> RegisterBackgroundWorker() succeeded or not, but an extension could
> check by itself using BackgroundWorkerList in bgworker_internals.h,
> and error out or something if it didn't succeed, as a way to inform
> users that they didn't configure the instance properly (like maybe
> increasing max_worker_processes).  Surely using a *_internals.h header
> is a clear sign that you expose yourself to problems, but adding an
> official way to check for bgworker registration doesn't seem
> unreasonable to me.  Is that worth the risk to have pg_upgrade
> erroring out in this kind of scenario, or make the addition of a new
> API to check for registration status more difficult?

Perhaps.  That feels like a topic different than what's discussed
here, though, because we don't really need to check if a bgworker has
been launched or not.  We just need to make sure that it never runs in
the context of a binary upgrade, like autovacuum.
--
Michael

Вложения

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

Предыдущее
От: Amit Kapila
Дата:
Сообщение: Re: Skipping logical replication transactions on subscriber side
Следующее
От: Greg Nancarrow
Дата:
Сообщение: Fix erroneous parallel execution when modifying CTE is present in rewritten query