Re: kevent latch paths don't handle postmaster death well

Tom Lane <tgl@sss.pgh.pa.us>

From: Tom Lane <tgl@sss.pgh.pa.us>
To: Thomas Munro <thomas.munro@gmail.com>
Cc: Heikki Linnakangas <hlinnaka@iki.fi>, PostgreSQL Hackers <pgsql-hackers@lists.postgresql.org>
Date: 2020-10-14T22:57:22Z
Lists: pgsql-hackers

Attachments

Thomas Munro <thomas.munro@gmail.com> writes:
> (Hmm, I wonder about that Windows process exit event.)

If anyone wants to test that, I can save you a little time building
infrastructure, perhaps.  I used the attached program built into a .so.
After creating the function, invoke it, and once it's blocked kill -9
the postmaster.  If it successfully reports multiple WL_POSTMASTER_DEATH
results then it's good.

			regards, tom lane

Commits

  1. Handle EACCES errors from kevent() better.

  2. Make WL_POSTMASTER_DEATH level-triggered on kqueue builds.