pgsql: Refactor receivelog.c parameters - Mailing list pgsql-committers

From Magnus Hagander
Subject pgsql: Refactor receivelog.c parameters
Date
Msg-id E1aeK6y-0005hF-44@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Refactor receivelog.c parameters

Much cruft had accumulated over time with a large number of parameters
passed down between functions very deep. With this refactoring, instead
introduce a StreamCtl structure that holds the parameters, and pass around
a pointer to this structure instead. This makes it much easier to add or
remove fields that are needed deeper down in the implementation without
having to modify every function header in the file.

Patch by me after much nagging from Andres
Reviewed by Craig Ringer and Daniel Gustafsson

Branch
------
master

Details
-------
http://git.postgresql.org/pg/commitdiff/38c83c9b7569378d864d8915e291716b8bec15f2

Modified Files
--------------
src/bin/pg_basebackup/pg_basebackup.c  |  18 +++-
src/bin/pg_basebackup/pg_receivexlog.c |  34 +++---
src/bin/pg_basebackup/receivelog.c     | 187 ++++++++++++++-------------------
src/bin/pg_basebackup/receivelog.h     |  33 ++++--
4 files changed, 136 insertions(+), 136 deletions(-)


pgsql-committers by date:

Previous
From: Simon Riggs
Date:
Subject: pgsql: Allow emit_log_hook to see original message text
Next
From: Robert Haas
Date:
Subject: pgsql: Fix a typo, and remove unnecessary pgstat_report_wait_end().