agora inbox for pgsql-hackers@postgresql.org  
help / color / mirror / Atom feed
From: Michael Paquier <michael@paquier.xyz>
To: Zsolt Parragi <zsolt.parragi@percona.com>
Cc: Nikolay Samokhvalov <nik@postgres.ai>
Cc: pgsql-hackers@lists.postgresql.org, Andrey Borodin <x4mmm@yandex-team.ru>
Subject: Re: injection_points: canceled or terminated waiters leak their wait slots
Date: Tue, 29 Sep 2026 07:57:54 +0900
Message-ID: <arrw8isOSbfkK5Fd@paquier.xyz> (raw)
In-Reply-To: <CAN4CZFPsHwozYFFXKQof349L6AiHqoSrm+oSajKBrGdCpG-=Tg@mail.gmail.com>
References: <CAN4CZFO+KF=cc0-iEg28RhqRBp_fTs6D4b8b7D7DB-pGYP3Ccg@mail.gmail.com>
	<amAc853flInQAEI5@paquier.xyz>
	<CAN4CZFM5KGB0tuw8LA9jtbDzsf1qa+UxSzYUuCUJuB12ym6DHw@mail.gmail.com>
	<amBjKAJLyPR5hdlE@paquier.xyz>
	<amGpM1v-hhvVav3n@paquier.xyz>
	<088AB35D-0860-494A-A9CF-8B301543AA51@yandex-team.ru>
	<CAM527d8gNR9MW-BSC=DFm7aufx6P+_hALSVr-ML9Er0KpE9jjQ@mail.gmail.com>
	<CAN4CZFPsHwozYFFXKQof349L6AiHqoSrm+oSajKBrGdCpG-=Tg@mail.gmail.com>

On Mon, Sep 28, 2026 at 10:12:37PM +0000, Zsolt Parragi wrote:
> I was able to reproduce the issue both on windows, and on linux by
> "patching" the server to reproduce the described behavior.

How exactly?

> The overall changes look good to me, it just needs some
> squashing/organizing to be a proper patchset.

TBH, I am not completely sure what you are proposing here.  v1-0001
from Andrey and AI-generated-not-reviewed 0003 from Nikolay step on
each other with the latter patch requiring the former patch, in terms
of the way the last buffered error messages can be consumed, which
should be either something local to try_complete_step() or tracked by
IsoConnInfo.  I'm OK with the basic idea of having more predictible
output here, with some alternate outputs to make the CI happier on
Windows, let's just organize a bit the whole..

-       SELECT pg_terminate_backend(pid) FROM pg_stat_activity
+       SELECT pg_terminate_backend(pid, 180000) FROM pg_stat_activity

Avoiding hardcoded timeouts would be nice.  They are not liked on slow
machines.
--
Michael

Attachments:

  [application/pgp-signature] signature.asc (832B, ../arrw8isOSbfkK5Fd@paquier.xyz/2-signature.asc)
  download

view thread (19+ messages)  latest in thread

Message-ID: <arrw8isOSbfkK5Fd@paquier.xyz>
Permalink:  ../arrw8isOSbfkK5Fd@paquier.xyz/
Also on:    postgresql.org/message-id/arrw8isOSbfkK5Fd@paquier.xyz

reply

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Reply to all the recipients using the --to and --cc options:
  reply via email

  To: pgsql-hackers@postgresql.org
  Cc: michael@paquier.xyz, zsolt.parragi@percona.com, nik@postgres.ai, x4mmm@yandex-team.ru
  Subject: Re: injection_points: canceled or terminated waiters leak their wait slots
  In-Reply-To: <arrw8isOSbfkK5Fd@paquier.xyz>

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

This inbox is served by agora; see mirroring instructions
for how to clone and mirror all data and code used for this inbox