Re: BUG #17903: There is a bug in the KeepLogSeg() - Mailing list pgsql-bugs

From Kyotaro Horiguchi
Subject Re: BUG #17903: There is a bug in the KeepLogSeg()
Date
Msg-id 20230428.152149.1957059339218200205.horikyota.ntt@gmail.com
Whole thread Raw
In response to Re: BUG #17903: There is a bug in the KeepLogSeg()  (Nathan Bossart <nathandbossart@gmail.com>)
List pgsql-bugs
At Thu, 27 Apr 2023 14:47:46 -0700, Nathan Bossart <nathandbossart@gmail.com> wrote in 
> On Tue, Apr 25, 2023 at 01:14:52PM +0900, Kyotaro Horiguchi wrote:
> > At Mon, 24 Apr 2023 12:14:52 -0700, Nathan Bossart <nathandbossart@gmail.com> wrote in 
> >> When determining the oldest segment that must be kept for
> >> replication slots, KeepLogSeg() might calculate a segment number
> >> ahead of the one for the LSN given to the function.  This causes
> > 
> > Maybe the KeepLogSeg() is a mistake of
> > XLogGetReplicationSlotMinimumLSN()?
> 
> I adjusted the commit message to call out that function explicitly.  Also,
> I decided to go with the "keep < recptr" approach since there's no reason
> to do anything in that block otherwise.

That works, too. Thanks!

regards.

-- 
Kyotaro Horiguchi
NTT Open Source Software Center



pgsql-bugs by date:

Previous
From: Kyotaro Horiguchi
Date:
Subject: Re: BUG #17804: Assertion failed in pg_stat after fetching from pg_stat_database and switching cache->snapshot
Next
From: Michael Paquier
Date:
Subject: Re: BUG #17804: Assertion failed in pg_stat after fetching from pg_stat_database and switching cache->snapshot