pgsql: Make error messages about WAL segment size more consistent - Mailing list pgsql-committers

From Peter Eisentraut
Subject pgsql: Make error messages about WAL segment size more consistent
Date
Msg-id E1qacF8-001Lin-Od@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Make error messages about WAL segment size more consistent

Make the primary messages more compact and make the detail messages
uniform.  In initdb.c and pg_resetwal.c, use the newish
option_parse_int() to simplify some of the option parsing.  For the
backend GUC wal_segment_size, add a GUC check hook to do the
verification instead of coding it in bootstrap.c.  This might be
overkill, but that way the check is in the right place and it becomes
more self-documenting.

In passing, make pg_controldata use the logging API for warning
messages.

Reviewed-by: Aleksander Alekseev <aleksander@timescale.com>
Discussion: https://www.postgresql.org/message-id/flat/9939aa8a-d7be-da2c-7715-0a0b5535a1f7@eisentraut.org

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/36e4419d1f1ef06bba58a28a870aaaa8de73bb46

Modified Files
--------------
src/backend/access/transam/xlog.c              | 19 ++++++++++++++++---
src/backend/bootstrap/bootstrap.c              | 11 +----------
src/backend/utils/misc/guc_tables.c            |  2 +-
src/bin/initdb/initdb.c                        | 25 ++++++-------------------
src/bin/pg_basebackup/streamutil.c             |  5 +++--
src/bin/pg_controldata/pg_controldata.c        | 23 +++++++++++------------
src/bin/pg_controldata/t/001_pg_controldata.pl |  6 +++---
src/bin/pg_resetwal/Makefile                   |  2 ++
src/bin/pg_resetwal/pg_resetwal.c              | 18 +++++++++++-------
src/bin/pg_rewind/pg_rewind.c                  | 12 ++++++++----
src/bin/pg_waldump/pg_waldump.c                | 12 ++++++++----
src/include/utils/guc_hooks.h                  |  1 +
12 files changed, 71 insertions(+), 65 deletions(-)


pgsql-committers by date:

Previous
From: Michael Paquier
Date:
Subject: pgsql: Fix some typos in wait_event_names.txt
Next
From: Tom Lane
Date:
Subject: pgsql: Stamp 16rc1.