Re: Replication slots and footguns

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Josh Berkus <josh(at)agliodbs(dot)com>
Cc: Andres Freund <andres(at)2ndquadrant(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Replication slots and footguns
Date: 2014-03-18 11:38:45
Message-ID: CA+TgmoY58PG2o3gGCSUPje+17dRTjd6k1yu-R8-XruWU7ipdVQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Mar 13, 2014 at 9:07 PM, Josh Berkus <josh(at)agliodbs(dot)com> wrote:
> On 03/13/2014 05:28 PM, Robert Haas wrote:
>> Well we may have kind of hosed ourselves, because the in-memory data
>> structures that represent the data structure have an in_use flag that
>> indicates whether the structure is allocated at all, and then an
>> active flag that indicates whether some backend is using it. I never
>> liked that naming much. Maybe we should go through and let in_use ->
>> allocated and active -> in_use.
>
> Wait, which one of those does pg_drop_replication_slot() care about?

Well... the slots that aren't in_use can't be dropped because they
don't exist in the first place. The ones that aren't active can't be
dropped because somebody else is using them. So both, sorta, I guess?

--
Robert Haas
EnterpriseDB: http://www.enterprisedb.com
The Enterprise PostgreSQL Company

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2014-03-18 11:59:17 pgsql: Make it easy to detach completely from shared memory.
Previous Message Robert Haas 2014-03-18 11:33:52 Re: Triggers on foreign tables