On Thu, Jan 08, 2026 at 09:57:38PM +0200, Heikki Linnakangas wrote:
> When an autovacuum worker exits, ProcKill() sends SIGUSR2 to the launcher. I
> propose moving that responsibility to the postmaster, because:
This seems generally reasonable to me. So does the patch.
> * It makes it consistent with background workers. When a background worker
> exits, the postmaster sends the signal to the launching process (if
> requested).
I've wondered about making autovacuum workers proper background workers.
> I'm a little surprised it wasn't done this way to begin with, so I wonder if
> I'm missing something?
This code dates back to commit e2a186b03c. I skimmed through the nearby
thread [0] and didn't immediately notice any discussion about this. My
guess is that it seemed simpler to directly alert the launcher, since it's
the one that needs to take action.
[0] https://postgr.es/m/flat/20070404233954.GK19251%40alvh.no-ip.org
--
nathan