Re: [bug fix] Produce a crash dump before main() on Windows - Mailing list pgsql-hackers

From Tom Lane
Subject Re: [bug fix] Produce a crash dump before main() on Windows
Date
Msg-id 5947.1563901608@sss.pgh.pa.us
Whole thread Raw
In response to Re: [bug fix] Produce a crash dump before main() on Windows  (Kyotaro Horiguchi <horikyota.ntt@gmail.com>)
Responses Re: [bug fix] Produce a crash dump before main() on Windows  (Alvaro Herrera <alvherre@2ndquadrant.com>)
List pgsql-hackers
Kyotaro Horiguchi <horikyota.ntt@gmail.com> writes:
> We are obliged to assume that we won't have the desired behavior
> without detecting whether running as a service or not.

> My investigation convinced me that there is no way for a process
> to detect wheter it is running as a service (except the process
> directly called from system (aka entry function)). In other
> words, only pg_ctl knows that and other processes doesn't have a
> clue for that. The processes other than postmaster can receive
> that information via backend variables. But the postmaster has no
> way to get the information from pg_ctl other than command line
> parameter, environment variable or filesystem (or PIPE?).

> If we see the complexity meets the benefit, we can use, say,
> command line parameter, WER dialog can be shown when server is
> started in console but the parameter being specified, but I don't
> think it is a problem.

Not being a Windows user, I don't have much to say about the big
question of whether disabling WER is still a good idea or not.  But
I will say that in my experience, behavioral differences between
Postgres started manually and Postgres started as a daemon are bad.
So I think going out of our way to make the cases behave differently
on Windows is probably not a good plan.

            regards, tom lane



pgsql-hackers by date:

Previous
From: Alvaro Herrera
Date:
Subject: Re: Change ereport level for QueuePartitionConstraintValidation
Next
From: Tom Lane
Date:
Subject: Re: [PATCH] Improve performance of NOTIFY over many databases (issue blocking on AccessExclusiveLock on object 0 of class 1262 of database 0)