pgsql: Expose control file data via SQL accessible functions. - Mailing list pgsql-committers

From Joe Conway
Subject pgsql: Expose control file data via SQL accessible functions.
Date
Msg-id E1acHbZ-0003Jz-Vb@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Expose control file data via SQL accessible functions.

Add four new SQL accessible functions: pg_control_system(),
pg_control_checkpoint(), pg_control_recovery(), and pg_control_init()
which expose a subset of the control file data.

Along the way move the code to read and validate the control file to
src/common, where it can be shared by the new backend functions
and the original pg_controldata frontend program.

Patch by me, significant input, testing, and review by Michael Paquier.

Branch
------
master

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

Modified Files
--------------
doc/src/sgml/func.sgml                  | 356 ++++++++++++++++++++++++++++++++
src/backend/utils/misc/Makefile         |   2 +-
src/backend/utils/misc/pg_controldata.c | 341 ++++++++++++++++++++++++++++++
src/bin/pg_controldata/pg_controldata.c | 162 ++++++---------
src/common/Makefile                     |   4 +-
src/common/controldata_utils.c          | 100 +++++++++
src/include/catalog/catversion.h        |   2 +-
src/include/catalog/pg_proc.h           |  13 ++
src/include/common/controldata_utils.h  |  15 ++
src/include/utils/builtins.h            |   6 +
src/tools/msvc/Mkvcbuild.pm             |   4 +-
11 files changed, 900 insertions(+), 105 deletions(-)


pgsql-committers by date:

Previous
From: Fujii Masao
Date:
Subject: pgsql: Ignore recovery_min_apply_delay until recovery has reached consi
Next
From: Andres Freund
Date:
Subject: pgsql: logical decoding: old/newtuple in spooled UPDATE changes was swi