Re: Sync Rep v19

From: Yeb Havinga <yebhavinga(at)gmail(dot)com>
To: Jaime Casanova <jaime(at)2ndquadrant(dot)com>
Cc: Robert Haas <robertmhaas(at)gmail(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Dimitri Fontaine <dimitri(at)2ndquadrant(dot)fr>, Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, pgsql-hackers(at)postgresql(dot)org
Subject: Re: Sync Rep v19
Date: 2011-03-04 22:20:14
Message-ID: 4D71659E.906@gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 2011-03-04 22:18, Jaime Casanova wrote:
> On Thu, Mar 3, 2011 at 1:23 PM, Robert Haas<robertmhaas(at)gmail(dot)com> wrote:
>>> The patch sets "*" as the default, so all standbys are synchronous by
>>> default.
>>>
>>> Would you prefer it if it was blank, meaning no standbys are
>>> synchronous, by default?
>> I think * is a reasonable default.
>>
> Actually i would prefer to have standbys asynchronous by default...
> though is true that there will be no waits until i set
> synchronous_replication to on... 1) it could be confusing to see a
> SYNC standby in pg_stat_replication by default when i wanted all of
> them to be async,
I see no problem with * for synchronous_standby names, such that *if*
synchronous_replication = on, then all standbys are sync. Also for the
beginning experimenter with sync rep: what would you expect after only
turning 'synchronous_replication' = on? ISTM better than : you need to
change two parameters from their default to get a replica in sync mode.
> 2) also * will give priority 1 to all standbys so it
> doesn't seem like a very useful out-of-the-box configuration, better
> to make the dba to write the standby names in the order they want
>
As somebody with a usecase for two hardware-wise equal sync replicas for
the same master (and a single async replica), the whole ordering of sync
standbys is too much feature anyway, since it will cause unneccesary
'which is the sync replica' switching. Besides that, letting all syncs
have the same priority sounds like the only thing the server can do, if
the dba has not specified it explicitly. I would see it as improvement
if order in standby_names doesn't mean priority, and that priority could
be specified with another parameter (and default: all sync priorities
the same)

regards,
Yeb Havinga

In response to

Browse pgsql-hackers by date

  From Date Subject
Next Message Simon Riggs 2011-03-04 22:28:42 Re: Sync Rep v19
Previous Message Robert Haas 2011-03-04 21:53:59 Re: Sync Rep v19