Re: allow online change primary_conninfo - Mailing list pgsql-hackers

From Sergei Kornilov
Subject Re: allow online change primary_conninfo
Date
Msg-id 680971579708266@myt3-e9df8ad73dde.qloud-c.yandex.net
Whole thread Raw
In response to Re: allow online change primary_conninfo  (Michael Paquier <michael@paquier.xyz>)
Responses Re: allow online change primary_conninfo  (Sergei Kornilov <sk@zsrv.org>)
List pgsql-hackers
Hello

> Yeah, you are right. I was not paying much attention but something
> does not stick here. My understanding is that we should have the WAL
> receiver receive the value it needs to use from the startup process
> (aka via RequestXLogStreaming from xlog.c), and that we ought to make
> this new parameter PGC_POSTMASTER instead of PGC_SIGHUP. HEAD is
> inconsistent here.

Thank you!

I attached two patches:
- first changes wal_receiver_create_temp_slot to PGC_POSTMASTER and moved the logic to RequestXLogStreaming
- second is based on last published v6 version of main patch. It changes wal_receiver_create_temp_slot back to
PGC_SIGHUPalong with primary_conninfo and primary_slot_name and will restart walreceiver if need.
 

Regarding the main patch: we have several possibilities for moving RequestXLogStreaming call. We need to choose one.
And, of course, changes in the text...

regards, Sergei
Attachment

pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: Do we need to handle orphaned prepared transactions in the server?
Next
From: Sergei Kornilov
Date:
Subject: Re: pgsql: walreceiver uses a temporary replication slot by default