Thread: pgsql: Hot Standby feedback for avoidance of cleanup conflicts on stand

pgsql: Hot Standby feedback for avoidance of cleanup conflicts on stand

From
Simon Riggs
Date:
Hot Standby feedback for avoidance of cleanup conflicts on standby.
Standby optionally sends back information about oldestXmin of queries
which is then checked and applied to the WALSender's proc->xmin.
GetOldestXmin() is modified slightly to agree with GetSnapshotData(),
so that all backends on primary include WALSender within their snapshots.
Note this does nothing to change the snapshot xmin on either master or
standby. Feedback piggybacks on the standby reply message.
vacuum_defer_cleanup_age is no longer used on standby, though parameter
still exists on primary, since some use cases still exist.

Simon Riggs, review comments from Fujii Masao, Heikki Linnakangas, Robert Haas

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/bca8b7f16a3e720794cb0afbdb3733be4f8d9c2c

Modified Files
--------------
doc/src/sgml/config.sgml                      |   20 +++++++
doc/src/sgml/high-availability.sgml           |   44 +++++++--------
src/backend/access/transam/xlog.c             |   58 +++++++++++++++++++--
src/backend/replication/walreceiver.c         |   36 +++++++++++-
src/backend/replication/walsender.c           |   71 ++++++++++++++++++++++++-
src/backend/storage/ipc/procarray.c           |   45 +++++++++------
src/backend/utils/misc/guc.c                  |    9 +++
src/backend/utils/misc/postgresql.conf.sample |    1 +
src/include/access/xlog.h                     |    1 +
src/include/replication/walprotocol.h         |    9 +++
src/include/replication/walreceiver.h         |    1 +
11 files changed, 245 insertions(+), 50 deletions(-)