mirror of
https://github.com/postgres/postgres.git
synced 2025-07-27 12:41:57 +03:00
Rename standby_slot_names to synchronized_standby_slots.
The standby_slot_names GUC allows the specification of physical standby slots that must be synchronized before the logical walsenders associated with logical failover slots. However, for this purpose, the GUC name is too generic. Author: Hou Zhijie Reviewed-by: Bertrand Drouvot, Masahiko Sawada Backpatch-through: 17 Discussion: https://postgr.es/m/ZnWeUgdHong93fQN@momjian.us
This commit is contained in:
@ -4569,10 +4569,10 @@ restore_command = 'copy "C:\\server\\archivedir\\%f" "%p"' # Windows
|
||||
</listitem>
|
||||
</varlistentry>
|
||||
|
||||
<varlistentry id="guc-standby-slot-names" xreflabel="standby_slot_names">
|
||||
<term><varname>standby_slot_names</varname> (<type>string</type>)
|
||||
<varlistentry id="guc-synchronized-standby-slots" xreflabel="synchronized_standby_slots">
|
||||
<term><varname>synchronized_standby_slots</varname> (<type>string</type>)
|
||||
<indexterm>
|
||||
<primary><varname>standby_slot_names</varname> configuration parameter</primary>
|
||||
<primary><varname>synchronized_standby_slots</varname> configuration parameter</primary>
|
||||
</indexterm>
|
||||
</term>
|
||||
<listitem>
|
||||
@ -4587,7 +4587,7 @@ restore_command = 'copy "C:\\server\\archivedir\\%f" "%p"' # Windows
|
||||
after the standby is promoted, the physical replication slot for the
|
||||
standby should be listed here. Note that logical replication will not
|
||||
proceed if the slots specified in the
|
||||
<varname>standby_slot_names</varname> do not exist or are invalidated.
|
||||
<varname>synchronized_standby_slots</varname> do not exist or are invalidated.
|
||||
Additionally, the replication management functions
|
||||
<link linkend="pg-replication-slot-advance">
|
||||
<function>pg_replication_slot_advance</function></link>,
|
||||
@ -4596,12 +4596,12 @@ restore_command = 'copy "C:\\server\\archivedir\\%f" "%p"' # Windows
|
||||
<link linkend="pg-logical-slot-peek-changes">
|
||||
<function>pg_logical_slot_peek_changes</function></link>,
|
||||
when used with logical failover slots, will block until all
|
||||
physical slots specified in <varname>standby_slot_names</varname> have
|
||||
physical slots specified in <varname>synchronized_standby_slots</varname> have
|
||||
confirmed WAL receipt.
|
||||
</para>
|
||||
<para>
|
||||
The standbys corresponding to the physical replication slots in
|
||||
<varname>standby_slot_names</varname> must configure
|
||||
<varname>synchronized_standby_slots</varname> must configure
|
||||
<literal>sync_replication_slots = true</literal> so they can receive
|
||||
logical failover slot changes from the primary.
|
||||
</para>
|
||||
|
@ -29057,7 +29057,7 @@ postgres=# SELECT '0/0'::pg_lsn + pd.segment_number * ps.setting::int + :offset
|
||||
adding the rows produced when decoding each new transaction commit.
|
||||
If the specified slot is a logical failover slot then the function will
|
||||
not return until all physical slots specified in
|
||||
<link linkend="guc-standby-slot-names"><varname>standby_slot_names</varname></link>
|
||||
<link linkend="guc-synchronized-standby-slots"><varname>synchronized_standby_slots</varname></link>
|
||||
have confirmed WAL receipt.
|
||||
</para></entry>
|
||||
</row>
|
||||
@ -29137,7 +29137,7 @@ postgres=# SELECT '0/0'::pg_lsn + pd.segment_number * ps.setting::int + :offset
|
||||
slot may return to an earlier position. If the specified slot is a
|
||||
logical failover slot then the function will not return until all
|
||||
physical slots specified in
|
||||
<link linkend="guc-standby-slot-names"><varname>standby_slot_names</varname></link>
|
||||
<link linkend="guc-synchronized-standby-slots"><varname>synchronized_standby_slots</varname></link>
|
||||
have confirmed WAL receipt.
|
||||
</para></entry>
|
||||
</row>
|
||||
|
@ -713,7 +713,7 @@ ALTER SUBSCRIPTION
|
||||
server before the failover happens. To ensure a successful failover, the
|
||||
standby server must be ahead of the subscriber. This can be achieved by
|
||||
configuring
|
||||
<link linkend="guc-standby-slot-names"><varname>standby_slot_names</varname></link>.
|
||||
<link linkend="guc-synchronized-standby-slots"><varname>synchronized_standby_slots</varname></link>.
|
||||
</para>
|
||||
|
||||
<para>
|
||||
|
@ -385,16 +385,16 @@ postgres=# select * from pg_logical_slot_get_changes('regression_slot', NULL, NU
|
||||
<literal>dbname</literal> in the
|
||||
<link linkend="guc-primary-conninfo"><varname>primary_conninfo</varname></link>.
|
||||
It's highly recommended that the said physical replication slot is named in
|
||||
<link linkend="guc-standby-slot-names"><varname>standby_slot_names</varname></link>
|
||||
<link linkend="guc-synchronized-standby-slots"><varname>synchronized_standby_slots</varname></link>
|
||||
list on the primary, to prevent the subscriber from consuming changes
|
||||
faster than the hot standby. Even when correctly configured, some latency
|
||||
is expected when sending changes to logical subscribers due to the waiting
|
||||
on slots named in
|
||||
<link linkend="guc-standby-slot-names"><varname>standby_slot_names</varname></link>.
|
||||
When <varname>standby_slot_names</varname> is utilized, the
|
||||
<link linkend="guc-synchronized-standby-slots"><varname>synchronized_standby_slots</varname></link>.
|
||||
When <varname>synchronized_standby_slots</varname> is utilized, the
|
||||
primary server will not completely shut down until the corresponding
|
||||
standbys, associated with the physical replication slots specified
|
||||
in <varname>standby_slot_names</varname>, have confirmed
|
||||
in <varname>synchronized_standby_slots</varname>, have confirmed
|
||||
receiving the WAL up to the latest flushed position on the primary server.
|
||||
</para>
|
||||
|
||||
|
@ -1350,7 +1350,7 @@ Author: Amit Kapila <akapila@postgresql.org>
|
||||
</para>
|
||||
|
||||
<para>
|
||||
The new server variable is <xref linkend="guc-standby-slot-names"/>.
|
||||
The new server variable is <xref linkend="guc-synchronized-standby-slots"/>.
|
||||
</para>
|
||||
</listitem>
|
||||
|
||||
|
Reference in New Issue
Block a user