Changes to error handling for background worker initialization?

From: Jeremy Finzel <finzelj(at)gmail(dot)com>
To: PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org>
Subject: Changes to error handling for background worker initialization?
Date: 2018-10-22 14:36:07
Message-ID: CAMa1XUi0g7KRbzcxPwNvBfGU2vh9A9jwHZ4EWTmaJzLrOhHA2Q@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hello -

I have an extension that uses background workers. I pass a database oid as
an argument in order to launch the worker using function
BackgroundWorkerInitializeConnectionByOid. In one of my regression tests
that was written, I intentionally launch the worker with an invalid oid.
In earlier PG versions the worker would successfully launch but then
terminate asynchronously, with a message in the server log. Now, it does
not even successfully launch but immediately errors (hence failing my
regression tests).

I have recently installed all later point releases of all versions 9.5-11,
so I assume this is due to some code change. The behavior seems reasonable
but I don't find any obvious release notes indicating a patch that would
have changed this behavior. Any thoughts?

Thanks,
Jeremy

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Alvaro Herrera 2018-10-22 15:36:25 Re: pgsql: Avoid duplicate XIDs at recovery when building initial snapshot
Previous Message Tom Lane 2018-10-22 14:17:31 Re: CVE-2017-7484-induced bugs, or, btree cmp functions are not leakproof?