pgsql: Add pg_promote function
Add pg_promote function
This function is able to promote a standby with this new SQL-callable
function. Execution access can be granted to non-superusers so that
failover tools can observe the principle of least privilege.
Catalog version is bumped.
Author: Laurenz Albe
Reviewed-by: Michael Paquier, Masahiko Sawada
Discussion: /messages/by-id/6e7c79b3ec916cf49742fb8849ed17cd87aed620.camel@cybertec.at
Branch
------
master
Details
-------
https://git.postgresql.org/pg/commitdiff/10074651e3355e2405015f6253602be8344bc829
Modified Files
--------------
doc/src/sgml/func.sgml | 19 ++++++++
doc/src/sgml/high-availability.sgml | 19 ++++----
doc/src/sgml/monitoring.sgml | 6 ++-
doc/src/sgml/recovery-config.sgml | 3 +-
src/backend/access/transam/xlog.c | 6 ---
src/backend/access/transam/xlogfuncs.c | 77 ++++++++++++++++++++++++++++++
src/backend/catalog/system_views.sql | 6 +++
src/backend/postmaster/pgstat.c | 3 ++
src/include/access/xlog.h | 6 +++
src/include/catalog/catversion.h | 2 +-
src/include/catalog/pg_proc.dat | 4 ++
src/include/pgstat.h | 1 +
src/test/recovery/t/004_timeline_switch.pl | 11 +++--
13 files changed, 143 insertions(+), 20 deletions(-)