Re: injection_points: Switch wait/wakeup to use atomics rather than latches

From: Andrey Borodin <x4mmm(at)yandex-team(dot)ru>
To: Michael Paquier <michael(at)paquier(dot)xyz>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Postgres hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org>, Heikki Linnakangas <hlinnaka(at)iki(dot)fi>
Subject: Re: injection_points: Switch wait/wakeup to use atomics rather than latches
Date: 2026-06-01 11:25:40
Message-ID: 46821C66-E6B2-420D-BB83-E20EF36665B8@yandex-team.ru
Views: Whole Thread | Raw Message | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

> On 30 May 2026, at 13:05, Andrey Borodin <x4mmm(at)yandex-team(dot)ru> wrote:
>
> I'll do another pass tomorrow, maybe something else will catch my eye.

I've tried the patch on my old corruption experiments. And it works for me.

I had to switch killing to something like
foreach my $i (1 .. 100)
{
my @alive = grep { kill 0, $_ } @cluster_pids;
last unless @alive;
kill 'KILL', @alive;
usleep(100_000);
}

The shared memory segment must be released before we attempt recovery.
But that's exactly what I wanted anyway. Thank you!

Best regards, Andrey Borodin.

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Ashutosh Bapat 2026-06-01 11:37:03 Re: (SQL/PGQ) cache lookup failed for label
Previous Message Etsuro Fujita 2026-06-01 10:44:34 Re: [(known) BUG] DELETE/UPDATE more than one row in partitioned foreign table