Re: Make query cancellation keys longer

Robert Haas <robertmhaas@gmail.com>

From: Robert Haas <robertmhaas@gmail.com>
To: Jelte Fennema-Nio <postgres@jeltef.nl>
Cc: Heikki Linnakangas <hlinnaka@iki.fi>, pgsql-hackers <pgsql-hackers@postgresql.org>, Thomas Munro <thomas.munro@gmail.com>
Date: 2025-02-26T20:18:45Z
Lists: pgsql-hackers
On Tue, Feb 25, 2025 at 9:28 AM Jelte Fennema-Nio <postgres@jeltef.nl> wrote:
> So to be clear: the current patchset *does not* change any client
> defaults. libpq will still connect to a server using the protocol
> version 3.0 by default. It will only connect with 3.2 unless
> instructed explicitly in the connection string using
> min/max_protocol_version. So no breakage by default is going to
> happen, and very few users will hit any breakage at all, because they
> won't change the default.

Ah, interesting. I didn't realize that you had done this in a way
where it wasn't enabled by default. I think that's different from what
was proposed before, but maybe I'm not remembering correctly.

-- 
Robert Haas
EDB: http://www.enterprisedb.com



Commits

  1. Add timingsafe_bcmp(), for constant-time memory comparison

  2. Add missing declarations to pg_config.h.in

  3. docs: Add a new section and a table listing protocol versions

  4. Make cancel request keys longer

  5. libpq: Add min/max_protocol_version connection options

  6. libpq: Handle NegotiateProtocolVersion message differently

  7. docs: Update phrase on message lengths in the protocol

  8. libpq: Trace all NegotiateProtocolVersion fields

  9. libpq: Add PQfullProtocolVersion to exports.txt

  10. Move cancel key generation to after forking the backend