Re: Outdated replication protocol error? - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Outdated replication protocol error?
Date
Msg-id 20210709011252.tqxim43c25vdz3vo@alap3.anarazel.de
Whole thread Raw
In response to Re: Outdated replication protocol error?  (Jeff Davis <pgsql@j-davis.com>)
List pgsql-hackers
Hi,

On 2021-06-17 18:13:57 -0700, Jeff Davis wrote:
> On Wed, 2021-06-16 at 16:17 -0700, Andres Freund wrote:
> > I think we should explicitly compute the current timeline before
> > using
> > ThisTimelineID. E.g. in StartReplication() call a new version of
> > GetFlushRecPtr() that also returns the current timeline id.
> 
> I think all we need to do is follow the pattern in IdentifySystem() by
> calling:
> 
>     am_cascading_walsender = RecoveryInProgress();
> 
> first.

Yea, that sounds reasonable.

I'm not a fan of hiding the timeline determination inside
RecoveryInProgress(), particularly not when communicated via global
variable. But that's not the fault of this patch.

Greetings,

Andres Freund



pgsql-hackers by date:

Previous
From: Fujii Masao
Date:
Subject: Re: Inaccurate error message when set fdw batch_size to 0
Next
From: Quan Zongliang
Date:
Subject: Re: bugfix: when the blocksize is 32k, the function page_header of pageinspect returns negative numbers.