Re: Patch: Don't set LoadedSSL unless secure_initialize succeeds - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Patch: Don't set LoadedSSL unless secure_initialize succeeds
Date
Msg-id 1413636.1653364285@sss.pgh.pa.us
Whole thread Raw
In response to Re: Patch: Don't set LoadedSSL unless secure_initialize succeeds  (Daniel Gustafsson <daniel@yesql.se>)
Responses Re: Patch: Don't set LoadedSSL unless secure_initialize succeeds  (Gurjeet Singh <gurjeet@singh.im>)
List pgsql-hackers
Daniel Gustafsson <daniel@yesql.se> writes:
>> On 22 May 2022, at 08:41, Gurjeet Singh <gurjeet@singh.im> wrote:
>> The initialization in PostmasterMain() blindly turns on LoadedSSL,
>> irrespective of the outcome of secure_initialize().

> This call is invoked with isServerStart set to true so any error in
> secure_initialize should error out with ereport FATAL (in be_tls_init()).  That
> could be explained in a comment though, which is currently isn't.

The comments for secure_initialize() and be_tls_init() both explain
this already.

It's not great that be_tls_init() implements two different error
handling behaviors, perhaps.  One could imagine separating those.
But we've pretty much bought into such messes with the very fact
that elog/ereport sometimes return and sometimes not.

            regards, tom lane



pgsql-hackers by date:

Previous
From: "bucoo"
Date:
Subject: partition wise aggregate wrong rows cost
Next
From: David Rowley
Date:
Subject: Re: partition wise aggregate wrong rows cost