Re: Sync Rep v19

From: Robert Haas <robertmhaas(at)gmail(dot)com>
To: Fujii Masao <masao(dot)fujii(at)gmail(dot)com>
Cc: Yeb Havinga <yebhavinga(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Sync Rep v19
Date: 2011-03-06 19:54:28
Message-ID: 72387015-6E0E-4271-8BBE-8B22DA23E12D@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On Mar 6, 2011, at 9:44 AM, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
> On Sun, Mar 6, 2011 at 5:02 PM, Yeb Havinga <yebhavinga(at)gmail(dot)com> wrote:
>> On Sun, Mar 6, 2011 at 8:58 AM, Fujii Masao <masao(dot)fujii(at)gmail(dot)com> wrote:
>>>
>>> If unfortunately all connection slots are used by backends waiting for
>>> replication, we cannot execute such a function. So it makes more sense
>>> to introduce something like "pg_ctl standalone" command?
>>
>> If it is only for shutdown, maybe pg_ctl stop -m standalone?
>
> It's for not only shutdown but also running the primary in standalone mode.
> So something like "pg_ctl standalone" is better.
>
> For now I think that pg_ctl command is better than built-in function because
> sometimes we might want to wake waiters up even during shutdown in
> order to cause shutdown to end. During shutdown, the server doesn't
> accept any new connection (even from the standby). So, without something
> like "pg_ctl standalone", there is no way to cause shutdown to end.

This sounds like an awful hack to work around a bad design. Surely once shutdown reaches a point where new replication connections can no longer be accepted, any standbys hung on commit need to close the connection without responding to the COMMIT, per previous discussion. It's completely unreasonable for sync rep to break the shutdown sequence.

...Robert

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2011-03-06 19:55:51 Re: default pg_hba vs replication
Previous Message Tom Lane 2011-03-06 17:16:48 Re: Alpha4 release blockers (was Re: wrapping up this CommitFest)