Logical decoding on standby - Mailing list pgsql-hackers

From Дмитрий Сарафанников
Subject Logical decoding on standby
Date
Msg-id 1453217433.421060638@f409.i.mail.ru
Whole thread Raw
Responses Re: Logical decoding on standby  (Alvaro Herrera <alvherre@2ndquadrant.com>)
Re: Logical decoding on standby  (Craig Ringer <craig@2ndquadrant.com>)
List pgsql-hackers
Hi,

If i try to create logical replication slot on standby i get error:
ERROR:  logical decoding cannot be used while in recovery

In code i found this comment:

/* ----
* TODO: We got to change that someday soon...
*
* There's basically three things missing to allow this:
* 1) We need to be able to correctly and quickly identify the timeline a
* LSN belongs to
* 2) We need to force hot_standby_feedback to be enabled at all times so
* the primary cannot remove rows we need.
* 3) support dropping replication slots referring to a database, in
* dbase_redo. There can't be any active ones due to HS recovery
* conflicts, so that should be relatively easy.
* ----
*/
if (RecoveryInProgress())
ereport(ERROR,
(errcode(ERRCODE_FEATURE_NOT_SUPPORTED),
errmsg("logical decoding cannot be used while in recovery")));
When you plan to add logical decoding on standby?

it is useful to have separate standby server for logical replication that will not break the master if you make a mistake in plugin.

--
Regards
Dmitriy

pgsql-hackers by date:

Previous
From: Dilip Kumar
Date:
Subject: Re: Move PinBuffer and UnpinBuffer to atomics
Next
From: Alvaro Herrera
Date:
Subject: Re: Logical decoding on standby