Re: injection_points: canceled or terminated waiters leak their wait slots - Mailing list pgsql-hackers

From Nikolay Samokhvalov
Subject Re: injection_points: canceled or terminated waiters leak their wait slots
Date
Msg-id CAM527d8gNR9MW-BSC=DFm7aufx6P+_hALSVr-ML9Er0KpE9jjQ@mail.gmail.com
Whole thread
In response to Re: injection_points: canceled or terminated waiters leak their wait slots  (Michael Paquier <michael@paquier.xyz>)
List pgsql-hackers
On Sun, Aug 23, 2026, Andrey Borodin <x4mmm@yandex-team.ru> wrote:
> The attached patch makes isolationtester treat PQconsumeInput() failure with
> CONNECTION_BAD as completion of the step.

Thanks Andrey. CF 6992 hit the same symptom in slot_creation_error on
Windows. Attached are three follow-ups on top of your v1.

There is another case with a notice blocker: try_complete_step() can return
while the step is still blocked, losing the saved connection error. The next
attempt then fails with "invalid socket". The fix keeps the error in
IsoConnInfo until the step completes. The other patches add the alternate
slot_creation_error output and extend wait_cleanup to cover this case.

With the extended test and the final ErrorResponse suppressed, v1 fails
before release3/detach3; the fixed version completes both. The suppression
is test-only and leaves the server's FATAL in the log. It does not force
Windows transport loss.

The Windows run below passed core regression/isolation, test_decoding,
injection_points isolation and subscription TAP (one ICU-dependent skip),
with your v1 plus these patches. The workflow includes setup, the missing
ErrorResponse test and old-driver controls:

https://github.com/NikolayS/postgres/actions/runs/35770093308

https://github.com/NikolayS/postgres/blob/8039ee47313f7ac860d26bd6fd9892c0ac296fee/.github/workflows/cf6992-windows-validation.yml

AI found the blocker case and prepared these follow-up patches.
I have not manually reviewed these patches.

Nik

Attachment

pgsql-hackers by date:

Previous
From: Rui Zhao
Date:
Subject: Re: index prefetching
Next
From: Nikolay Samokhvalov
Date:
Subject: Re: xact_rollback spikes when logical walsender exits