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-14 00:28:16
Message-ID: CA+TgmoYTgPN8OuB+ewAsP6q90-q_1_y99p_seRXG0z=nLZDZqw@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Thu, Mar 13, 2014 at 8:09 PM, Josh Berkus <josh(at)agliodbs(dot)com> wrote:
> On 03/13/2014 05:01 PM, Robert Haas wrote:
>> On Thu, Mar 13, 2014 at 6:45 PM, Josh Berkus <josh(at)agliodbs(dot)com> wrote:
>>> On 03/13/2014 01:17 PM, Robert Haas wrote:
>>>> I think "in use" is just as clear as active, and I think the text
>>>> Andres proposed previously reads a whole lot more nicely than this:
>>>>
>>>> replication slot "%s" is in use by another backend
>>>
>>> Then we should change the column name in the pg_stat_replication_slots
>>> view to "in_use". My point is that the error message and the diagnostic
>>> view should use the same word, or we're needlessly confusing our users.
>>
>> I see. That's an interesting point....
>
> As I said earlier, the fact that the current error message says "active"
> and the column in pg_stat_replication_slots is called "active" meant I
> knew *immediately* where to look. So I'm speaking from personal experience.

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.

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

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Josh Berkus 2014-03-14 01:07:38 Re: Replication slots and footguns
Previous Message Josh Berkus 2014-03-14 00:09:25 Re: Replication slots and footguns