Re: BackendKeyData is mandatory? - Mailing list pgsql-hackers

From David G. Johnston
Subject Re: BackendKeyData is mandatory?
Date
Msg-id CAKFQuwZrnMvdPTZ90p-a_u+Om9A=ePT=gM_vqFmQBVBtmkWQbw@mail.gmail.com
Whole thread Raw
In response to Re: BackendKeyData is mandatory?  (Tatsuo Ishii <ishii@postgresql.org>)
Responses Re: BackendKeyData is mandatory?
List pgsql-hackers
On Thursday, June 19, 2025, Tatsuo Ishii <ishii@postgresql.org> wrote:
> FWIW my reading of the protocol docs is that BackendKeyData is
> optional.

If majority of developers think so, do we want to update the protocol
docs?  For me the docs is not clear enough.

At this point why does it matter what the docs says?  You know what exists in reality and you can either change or not.

That said, the documentation makes it clear that absent an error the server shall send:

2 or more (some) ParameterStatus messages
Followed by
1 BackendKeyData message
Followed by
1 ReadyForQuery message

So the protocol is violated if the BackendKeyData is absent.  I don’t see why we should change that since we adhere to it and it’s our protocol; but also its absence is non-fatal to the typical operation of the server…

David J.

pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: Non-reproducible AIO failure
Next
From: Peter Eisentraut
Date:
Subject: Re: Add CASEFOLD() function.