Re: Don'st start streaming after creating a slot in pg_receivexlog - Mailing list pgsql-hackers

From Andres Freund
Subject Re: Don'st start streaming after creating a slot in pg_receivexlog
Date
Msg-id 20150729131539.GA26516@alap3.anarazel.de
Whole thread Raw
In response to Re: Don'st start streaming after creating a slot in pg_receivexlog  (Simon Riggs <simon@2ndQuadrant.com>)
Responses Re: Don'st start streaming after creating a slot in pg_receivexlog
List pgsql-hackers
On 2015-07-29 13:53:31 +0100, Simon Riggs wrote:
> It makes more sense to create one new utility to issue replication commands
> than to enhance multiple utility commands to have bizarre looking
> additional features and modes.
> 
> pg_reputil --create-slot
> pg_reputil --drop-slot
> etc

Logical slots behave differently than physical slots and need different
options. So to me there's a fair point in having support for
manipulating logical slot in a tool around logical slots.

Additionally that support was there in 9.4 and I know at least of three
scripts that call pg_recvlogical to create logical slots. Admittedly one
of them is of my own creation.

> though I prefer the idea of using psql and the already existing slot
> functions than doing all of this extra code that needs maintaining.

It's not that uncommon to have replicas only access the primary for
replication type connections. So it seems completely sensible to use the
replication protocol to manage slots. And that you can't really do with
psql.

Andres



pgsql-hackers by date:

Previous
From: Andres Freund
Date:
Subject: Re: LWLock deadlock and gdb advice
Next
From: Michael Paquier
Date:
Subject: Re: Don'st start streaming after creating a slot in pg_receivexlog