| From: | Thomas Munro <thomas(dot)munro(at)gmail(dot)com> |
|---|---|
| To: | Michael Paquier <michael(at)paquier(dot)xyz> |
| Cc: | Fujii Masao <masao(dot)fujii(at)oss(dot)nttdata(dot)com>, David Rowley <dgrowleyml(at)gmail(dot)com>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>, pgsql-hackers <pgsql-hackers(at)postgresql(dot)org> |
| Subject: | Re: PostmasterIsAlive() in recovery (non-USE_POST_MASTER_DEATH_SIGNAL builds) |
| Date: | 2021-03-11 03:37:39 |
| Message-ID: | CA+hUKGJ_pLdb8GJWwAPpiichdBWUYMRBLm10s_GHLA4fBcrZQw@mail.gmail.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-hackers |
On Tue, Mar 2, 2021 at 2:10 PM Thomas Munro <thomas(dot)munro(at)gmail(dot)com> wrote:
> ... One question I haven't
> got to the bottom of: is it a problem for the startup process that CVs
> use CHECK_FOR_INTERRUPTS()?
This was a red herring. The startup process already reaches CFI() via
various paths, as I figured out pretty quickly with a debugger. So
I'd like to go ahead and commit these patches.
Michael, when you said "That's pretty hack-ish, still efficient" in
reference to this code:
> - if (IsUnderPostmaster && !PostmasterIsAlive())
> + if (IsUnderPostmaster &&
> +#ifndef USE_POSTMASTER_DEATH_SIGNAL
> + count++ % 1024 == 0 &&
> +#endif
> + !PostmasterIsAlive())
Is that an objection, and do you see a specific better way?
I know that someone just needs to write a Windows patch to get us a
postmaster death signal when the postmaster's event fires, and then
the problem will go away on Windows. I still want this change,
because we don't have such a patch yet, and even when someone writes
that, there are still a couple of Unixes that could benefit.
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Amit Kapila | 2021-03-11 03:58:45 | Re: [PATCH] Provide more information to filter_prepare |
| Previous Message | Andres Freund | 2021-03-11 03:21:00 | Re: shared-memory based stats collector |