Re: BUG #15641: Autoprewarm worker fails to start on Windows withhuge pages in use Old PostgreSQL community/pgsql-bugs x

Поиск
Список
Период
Сортировка
On Mon, Mar 18, 2019 at 3:04 AM Mithun Cy <mithun.cy@gmail.com> wrote:
> autoprewarm waorker should not be restarted. As per the code @apw_start_database_worker@ master starts a worker per
databaseand wait until it exit by calling WaitForBackgroundWorkerShutdown.  The call WaitForBackgroundWorkerShutdown
cannothandle the case if the worker was restarted. The WaitForBackgroundWorkerShutdown() get the status BGWH_STOPPED
fromthe call GetBackgroundWorkerPid() if worker got restarted. So master will next detach the shared memory and next
restartedworker keep failing going in a unending loop. 

Ugh, that seems like a silly oversight.  Does it fix the reported problem?

If I understand correctly, the commit message would be something like this:

==
Don't auto-restart per-database autoprewarm workers.

We should try to prewarm each database only once.  Otherwise, if
prewarming fails for some reason, it will just keep retrying in an
infnite loop.  The existing code was intended to implement this
behavior, but because it neglected to set worker.bgw_restart_time, the
per-database workers keep restarting, contrary to what was intended.

Mithun Cy, per a report from Hans Buschmann
==

Does that sound right?

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company


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

Предыдущее
От: Paul Ramsey
Дата:
Сообщение: Re: Compressed TOAST Slicing
Следующее
От: Peter Eisentraut
Дата:
Сообщение: Re: pg_basebackup ignores the existing data directory permissions