From: | Magnus Hagander <magnus(at)hagander(dot)net> |
---|---|
To: | PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Function to control physical replication slot |
Date: | 2017-04-11 09:15:18 |
Message-ID: | CABUevEwBe0GckQpGxjSLccGR351nzbA3asrwRTVQ5=VV+S0+fQ@mail.gmail.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Is there a particular reason we don't have a function to *set* the
restart_lsn of a replication slot, other than to drop it and recreate it?
Similarly, to create one with a fixed value for restart_lsn and not
necessarily the one the machine is at right now?
Basically I'm doing a small script that keeps a replication slot on the
standby reasonably in sync with the master, for use in the case of a
failover.
AFAICT the only way to do it now is to either connect with the replication
protocol and actually consume the data (which seems quite wasteful), or to
drop and recreate the slot (in which case we can't actually determine the
location it gets set to keep, because it will be set to "whatever is
current").
--
Magnus Hagander
Me: https://www.hagander.net/ <http://www.hagander.net/>
Work: https://www.redpill-linpro.com/ <http://www.redpill-linpro.com/>
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Langote | 2017-04-11 09:16:51 | Re: Partitioned tables and relfilenode |
Previous Message | Etsuro Fujita | 2017-04-11 09:13:27 | Re: postgres_fdw bug in 9.6 |