pgsql: Add a common function to generate the origin name. - Mailing list pgsql-committers

From Amit Kapila
Subject pgsql: Add a common function to generate the origin name.
Date
Msg-id E1oi7ha-001qle-3I@gemulon.postgresql.org
Whole thread Raw
List pgsql-committers
Add a common function to generate the origin name.

Make a common replication origin name formatting function to replace
multiple snprintf() expressions. This also includes logic previously done
by ReplicationOriginNameForTablesync().

This makes the code to generate the origin name consistent among apply
worker and tablesync worker.

Author: Peter Smith
Reviewed-By: Aleksander Alekseev
Discussion: https://postgr.es/m/CAHut%2BPsa8hhfSE6ozUK-ih7GkQziAVAf4f3bqiXEj2nQiu-43g%40mail.gmail.com

Branch
------
master

Details
-------
https://git.postgresql.org/pg/commitdiff/776e1c8a5d1494e345e5e1b16a5eba5e98aaddca

Modified Files
--------------
src/backend/commands/subscriptioncmds.c     | 15 ++++++------
src/backend/replication/logical/tablesync.c | 36 ++++++++++-------------------
src/backend/replication/logical/worker.c    | 35 ++++++++++++++++++++++++----
src/include/replication/worker_internal.h   |  4 ++--
4 files changed, 52 insertions(+), 38 deletions(-)


pgsql-committers by date:

Previous
From: Michael Paquier
Date:
Subject: pgsql: Add TAP tests for role membership in pg_hba.conf
Next
From: Alvaro Herrera
Date:
Subject: pgsql: Ensure all perl test modules are installed