Re: Race condition in InvalidateObsoleteReplicationSlots()
vignesh C <vignesh21@gmail.com>
From: vignesh C <vignesh21@gmail.com>
To: Álvaro Herrera <alvherre@alvh.no-ip.org>
Cc: Pg Hackers <pgsql-hackers@postgresql.org>
Date: 2021-07-05T16:47:20Z
Lists: pgsql-hackers
On Wed, Jun 23, 2021 at 7:32 PM Álvaro Herrera <alvherre@alvh.no-ip.org> wrote: > > On 2021-Jun-20, Tom Lane wrote: > > > Actually ... isn't there a second race, in the opposite direction? > > IIUC, the point of this is that once we force some WAL to be sent > > to the frozen sender/receiver, they'll be killed for failure to > > respond. But the advance_wal call is not the only possible cause > > of that; a background autovacuum for example could emit some WAL. > > So I fear it's possible for the 'to release replication slot' > > message to come out before we capture $logstart. I think you > > need to capture that value before the kill not after. > > I accounted for all those things and pushed again. I saw that this patch is pushed. If there is no pending work left for this, can we change the commitfest entry to Committed. Regards, Vignesh
Commits
-
Add test case for obsoleting slot with active walsender, take 2
- 24043c27b46f 14.0 landed
-
Add test case for obsoleting slot with active walsender
- 09126984a263 14.0 landed
-
Return ReplicationSlotAcquire API to its original form
- 1632ea43682f 14.0 landed
-
Fix race condition in invalidating obsolete replication slots
- 96540f80f833 14.0 landed
- 218b101008b5 13.4 landed
-
Fix issues in invalidation of obsolete replication slots.
- f9e9704f09da 14.0 cited
-
Allow users to limit storage reserved by replication slots
- c6550776394e 13.0 cited