Re: pg_receivexlog and replication slots - Mailing list pgsql-hackers

From Alvaro Herrera
Subject Re: pg_receivexlog and replication slots
Date
Msg-id 20141001142112.GT5311@eldon.alvh.no-ip.org
Whole thread Raw
In response to Re: pg_receivexlog and replication slots  (Andres Freund <andres@2ndquadrant.com>)
Responses Re: pg_receivexlog and replication slots
List pgsql-hackers
Andres Freund wrote:

> From d667f7a63cd62733d88ec5b7228dfd5d7136b9d7 Mon Sep 17 00:00:00 2001
> From: Michael Paquier <michael@otacoo.com>
> Date: Mon, 1 Sep 2014 20:48:43 +0900
> Subject: [PATCH 3/4] Refactoring of pg_basebackup utilities
> 
> Code duplication is reduced with the introduction of new APIs for each
> individual replication command:
> - IDENTIFY_SYSTEM
> - CREATE_REPLICATION_SLOT
> - DROP_REPLICATION_SLOT
> A couple of variables used to identify a timeline ID are changed as well
> to be more consistent with core code.
> ---
>  src/bin/pg_basebackup/pg_basebackup.c  |  21 +----
>  src/bin/pg_basebackup/pg_receivexlog.c |  38 ++------
>  src/bin/pg_basebackup/pg_recvlogical.c | 116 ++++++------------------
>  src/bin/pg_basebackup/streamutil.c     | 159 +++++++++++++++++++++++++++++++++
>  src/bin/pg_basebackup/streamutil.h     |  10 +++
>  5 files changed, 207 insertions(+), 137 deletions(-)

Not objecting to any of this, but isn't it a bit funny that a patch that
aims to reduce duplication ends up with more lines than there were
originally?

-- 
Álvaro Herrera                http://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Training & Services



pgsql-hackers by date:

Previous
From: Heikki Linnakangas
Date:
Subject: Re: "Value locking" Wiki page
Next
From: Heikki Linnakangas
Date:
Subject: Re: open items for 9.4