Re: BackendKeyData is mandatory?
Tom Lane <tgl@sss.pgh.pa.us>
From: Tom Lane <tgl@sss.pgh.pa.us>
To: Jelte Fennema-Nio <postgres@jeltef.nl>
Cc: Jacob Champion <jacob.champion@enterprisedb.com>,
Tatsuo Ishii <ishii@postgresql.org>, hlinnaka@iki.fi,
peter@eisentraut.org, pgsql-hackers@postgresql.org
Date: 2025-06-23T19:48:10Z
Lists: pgsql-hackers
Jelte Fennema-Nio <postgres@jeltef.nl> writes: > On Mon, 23 Jun 2025 at 18:42, Jacob Champion > <jacob.champion@enterprisedb.com> wrote: >> From reading this thread, I'm not convinced that's "clear". I wouldn't >> have chosen the existing behavior, for sure, but any existing servers >> that don't send a key must be doing _something_ with that cancel >> request, right? Even if it's just ignored? > I mean if the only thing a server can do is ignore it, ISTM that it's > clearly useless to send it anyway. Sending nothing seems a much better > choice in that case. It could be that the server has some independent way of knowing which session to cancel. (As a reductio-ad-absurdum case, maybe it only supports one session.) >> Do we know which implementations aren't sending keys? > Nope, that's totally unclear. It would be very nice knowing which > database this is, and if it's at all a production system. Yeah, I'm very hesitant to spend any effort here without having a more concrete use-case. regards, tom lane
Commits
-
Revert unnecessary check for NULL
- 5a26a3e4eeb2 18.0 landed
- 807ee417e562 19 (unreleased) landed
-
libpq: Be strict about cancel key lengths
- e7ff96853ea7 18.0 landed
- e411a8d25a4b 19 (unreleased) landed
-
libpq: Handle OOM by disconnecting instead of hanging or skipping msgs
- 8aa287c9061b 18.0 landed
- f6f0542266f0 19 (unreleased) landed
-
libpq: Complain about missing BackendKeyData later with PGgetCancel()
- 42b1480eb2c6 18.0 landed
- a4801eb691ed 19 (unreleased) landed