pgsql: Track the oldest XID that can be safely looked up in CLOG.

From: Robert Haas <rhaas(at)postgresql(dot)org>
To: pgsql-committers(at)postgresql(dot)org
Subject: pgsql: Track the oldest XID that can be safely looked up in CLOG.
Date: 2017-03-23 18:29:33
Message-ID: E1cr7UL-0002Ly-BC@gemulon.postgresql.org
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-committers

Track the oldest XID that can be safely looked up in CLOG.

This provides infrastructure for looking up arbitrary, user-supplied
XIDs without a risk of scary-looking failures from within the clog
module. Normally, the oldest XID that can be safely looked up in CLOG
is the same as the oldest XID that can reused without causing
wraparound, and the latter is already tracked. However, while
truncation is in progress, the values are different, so we must
keep track of them separately.

Craig Ringer, reviewed by Simon Riggs and by me.

Discussion: http://postgr.es/m/CAMsr+YHQiWNEi0daCTboS40T+V5s_+dst3PYv_8v2wNVH+Xx4g@mail.gmail.com

Branch
------
master

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

Modified Files
--------------
doc/src/sgml/monitoring.sgml | 4 +++
src/backend/access/rmgrdesc/clogdesc.c | 12 +++++++--
src/backend/access/transam/clog.c | 46 +++++++++++++++++++++++++-------
src/backend/access/transam/transam.c | 4 +--
src/backend/access/transam/varsup.c | 23 +++++++++++++++-
src/backend/access/transam/xlog.c | 11 ++++++++
src/backend/commands/vacuum.c | 2 +-
src/backend/storage/lmgr/lwlocknames.txt | 1 +
src/include/access/clog.h | 8 +++++-
src/include/access/transam.h | 7 +++++
src/include/access/xlog_internal.h | 2 +-
11 files changed, 102 insertions(+), 18 deletions(-)

Browse pgsql-committers by date

  From Date Subject
Next Message Peter Eisentraut 2017-03-23 19:33:53 pgsql: ICU support
Previous Message Peter Eisentraut 2017-03-23 18:25:43 pgsql: Remove createlang and droplang