Allow setting failover property in the replication command.
Amit Kapila <akapila@postgresql.org>
Allow setting failover property in the replication command. This commit implements a new replication command called ALTER_REPLICATION_SLOT and a corresponding walreceiver API function named walrcv_alter_slot. Additionally, the CREATE_REPLICATION_SLOT command has been extended to support the failover option. These new additions allow the modification of the failover property of a replication slot on the publisher. A subsequent commit will make use of these commands in subscription commands and will add the tests as well to cover the functionality added/changed by this commit. Author: Hou Zhijie, Shveta Malik Reviewed-by: Peter Smith, Bertrand Drouvot, Dilip Kumar, Masahiko Sawada, Nisha Moond, Kuroda, Hayato, Amit Kapila Discussion: https://postgr.es/m/514f6f2f-6833-4539-39f1-96cd1e011f23@enterprisedb.com
Files
| Path | Change | +/− |
|---|---|---|
| doc/src/sgml/protocol.sgml | modified | +50 −0 |
| src/backend/commands/subscriptioncmds.c | modified | +1 −1 |
| src/backend/replication/libpqwalreceiver/libpqwalreceiver.c | modified | +42 −2 |
| src/backend/replication/logical/tablesync.c | modified | +1 −0 |
| src/backend/replication/repl_gram.y | modified | +18 −2 |
| src/backend/replication/repl_scanner.l | modified | +2 −0 |
| src/backend/replication/slot.c | modified | +25 −0 |
| src/backend/replication/walreceiver.c | modified | +1 −1 |
| src/backend/replication/walsender.c | modified | +59 −3 |
| src/include/nodes/replnodes.h | modified | +12 −0 |
| src/include/replication/slot.h | modified | +1 −0 |
| src/include/replication/walreceiver.h | modified | +16 −2 |
| src/tools/pgindent/typedefs.list | modified | +2 −0 |
Documentation touched
Discussion
- Synchronizing slots from primary to standby 936 messages · 2021-10-31 → 2024-06-07