Re: DROP SUBSCRIPTION with no slot - Mailing list pgsql-hackers

From Isaac Morland
Subject Re: DROP SUBSCRIPTION with no slot
Date
Msg-id CAMsGm5fx5821uhBgEKDtt8mJv5JAYf22uVv-XtKrxuO1BCohpg@mail.gmail.com
Whole thread Raw
In response to Re: DROP SUBSCRIPTION with no slot  (Žiga Kranjec <ziga@ljudmila.org>)
List pgsql-hackers
On Wed, 25 Sep 2019 at 13:55, Žiga Kranjec <ziga@ljudmila.org> wrote:

Ah. I missed that bit in the documentation!

Perhaps a publication should remember, whether it actually created a replication slot and only try to remove it, if it did. Although that probably wouldn't help much in your case.

What about issuing a NOTICE if the slot doesn't exist? I'm thinking if it is able to connect to the primary and issue the command to delete the slot, but it doesn't exist, not in case of arbitrary errors. I believe there is precedent for similar behaviour from all the DROP ... IF EXISTS commands. 

pgsql-hackers by date:

Previous
From: Žiga Kranjec
Date:
Subject: Re: DROP SUBSCRIPTION with no slot
Next
From: Ahsan Hadi
Date:
Subject: Re: Proposal for syntax to support creation of partition tables whencreating parent table