Re: [bug fix] Produce a crash dump before main() on Windows

Поиск
Список
Период
Сортировка
От Michael Paquier
Тема Re: [bug fix] Produce a crash dump before main() on Windows
Дата
Msg-id 20190911025729.GD1953@paquier.xyz
обсуждение исходный текст
Ответ на RE: [bug fix] Produce a crash dump before main() on Windows  ("Tsunakawa, Takayuki" <tsunakawa.takay@jp.fujitsu.com>)
Ответы RE: [bug fix] Produce a crash dump before main() on Windows  ("Tsunakawa, Takayuki" <tsunakawa.takay@jp.fujitsu.com>)
Список pgsql-hackers
On Tue, Sep 10, 2019 at 06:44:48AM +0000, Tsunakawa, Takayuki wrote:
> We don't have to call pgwin32_is_service() to determine whether we
> call SetErrorMode() in postmaster.c because:
>
> * The dialog box doesn't appear under Windows service, whether
> * PostgreSQL itself starts as a service or another (server)
> * application runs as a service and does "pg_ctl start."
>
> * It's OK for the dialog box to appear when the user runs "pg_ctl
> * start" on the command prompt.  That usage is interactive, and
> * should not be for production use (postgres processes vanish when
> * the user mistakenly presses Ctrl+C, or closes the command prompt).
> * Even now, the dialog box pops up if postmaster crashes before
> * main().

Reading the thread again from scratch, I am under the impression that
we do not have an actual consensus on this patch :)

Doesn't your first bullet point actually contradict the second one?
Your second point looks sensible from a usage point of view (aka show
a box when pg_ctl start fails from the command prompt because somebody
typed the command manually), however I am really worried about the
first point.  Imagine an application which relies on Postgres, still
does *not* start it as a service but uses "pg_ctl start"
automatically.  This could be triggered as part of another service
startup which calls say system(), or as another script.  Wouldn't that
cause potentially a freeze?  I am also not sure that I quite
understand why a popup would never show up if a different service
startup triggers pg_ctl start by itself that fails.
--
Michael

Вложения

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

Предыдущее
От: "Tsunakawa, Takayuki"
Дата:
Сообщение: RE: SIGQUIT on archiver child processes maybe not such a hot idea?
Следующее
От: Michael Paquier
Дата:
Сообщение: Re: Change atoi to strtol in same place