From: | Alvaro Herrera <alvherre(at)2ndquadrant(dot)com> |
---|---|
To: | Robert Haas <robertmhaas(at)gmail(dot)com> |
Cc: | Petr Jelinek <petr(dot)jelinek(at)2ndquadrant(dot)com>, Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>, Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, PostgreSQL mailing lists <pgsql-hackers(at)postgresql(dot)org> |
Subject: | Re: logical replication syntax (was DROP SUBSCRIPTION, query cancellations and slot handling) |
Date: | 2017-05-02 21:15:30 |
Message-ID: | 20170502211530.knjb72uo2lykuzxt@alvherre.pgsql |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-hackers |
Robert Haas wrote:
> On Tue, May 2, 2017 at 12:25 PM, Alvaro Herrera
> <alvherre(at)2ndquadrant(dot)com> wrote:
> > 2) don't drop because we know it won't work. I see two options:
> > c) ignore a drop slot failure, i.e. don't cause a transaction abort.
> > An easy way to implement this is just add a PG_TRY block, but we
> > dislike adding those and not re-throwing the error.
>
> Dislike doesn't seem like the right word. Unless you rollback a
> (sub)transaction, none of the cleanup that would normally do is done,
True. So one possible implementation is that we open a subtransaction
before dropping the slot, and we abort it if things go south. This is a
bit slower, but not critically so.
--
Álvaro Herrera https://www.2ndQuadrant.com/
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services
From | Date | Subject | |
---|---|---|---|
Next Message | Merlin Moncure | 2017-05-02 21:23:16 | Re: CTE inlining |
Previous Message | Robert Haas | 2017-05-02 20:40:01 | Re: logical replication syntax (was DROP SUBSCRIPTION, query cancellations and slot handling) |