From: | Amit Kapila <amit(dot)kapila16(at)gmail(dot)com> |
---|---|
To: | Fabrice Chapuis <fabrice636861(at)gmail(dot)com> |
Cc: | "Zhijie Hou (Fujitsu)" <houzj(dot)fnst(at)fujitsu(dot)com>, PostgreSQL Hackers <pgsql-hackers(at)lists(dot)postgresql(dot)org> |
Subject: | Re: failover logical replication slots |
Date: | 2025-06-12 09:37:28 |
Message-ID: | CAA4eK1Li9RO0nWbpV+JnjfqVLwdh_44ZQo=JWz7Z8DZ40_uiUA@mail.gmail.com |
Views: | Whole Thread | Raw Message | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
On Thu, Jun 12, 2025 at 2:32 PM Fabrice Chapuis <fabrice636861(at)gmail(dot)com> wrote:
>
> Thanks for the reply Amit,
>
> I don't really understand the logic of the implementation. If the slot name matches that of the primary slot and this slot is in failover mode, how could it be any different on the standby slot?
>
On the standby's we do allow creating logical slots (For example, one
can use pg_create_logical_replication_slot()). So, the same name slot
can be created on standby by the user before we start sync. As of now,
we don't allow setting the failover option for slots on standby's but
in future, it could be supported to allow syncing slots from standbys
(something like cascaded replication).
> After the first failover, the following failovers will work given that the sync flag is true on both the primary and standby slots.
>
> After new sandby is attached to the primary, can we imagine that when the sync worker process is started we check if a failover slot exists on the standby, if so we drop it before recreating a new one for syncing?
>
This has the risk of dropping an unwarranted slot.
--
With Regards,
Amit Kapila.
From | Date | Subject | |
---|---|---|---|
Next Message | Amit Kapila | 2025-06-12 10:05:56 | Re: failover logical replication slots |
Previous Message | Tatsuo Ishii | 2025-06-12 09:34:34 | Re: [PATCH] Proposal: Improvements to PDF stylesheet and table column widths |