Re: Support for N synchronous standby servers - take 2

From: Simon Riggs <simon(at)2ndQuadrant(dot)com>
To: Robert Haas <robertmhaas(at)gmail(dot)com>
Cc: Michael Paquier <michael(dot)paquier(at)gmail(dot)com>, Simon Riggs <simon(at)2ndquadrant(dot)com>, Josh Berkus <josh(at)agliodbs(dot)com>, Sawada Masahiko <sawada(dot)mshk(at)gmail(dot)com>, Fujii Masao <masao(dot)fujii(at)gmail(dot)com>, Beena Emerson <memissemerson(at)gmail(dot)com>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>
Subject: Re: Support for N synchronous standby servers - take 2
Date: 2015-07-16 17:32:46
Message-ID: CANP8+jJw4vt+wfs-OEb-ZRbQ2FoWVw-aSAfBUyQdQH-71k3ywQ@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

On 16 July 2015 at 18:27, Robert Haas <robertmhaas(at)gmail(dot)com> wrote:

> On Wed, Jul 15, 2015 at 5:03 AM, Michael Paquier
> <michael(dot)paquier(at)gmail(dot)com> wrote:
> >> Group labels are essential.
> >
> > OK, so this is leading us to the following points:
> > - Use a JSON object to define the quorum/priority groups for the sync
> state.
> > - Store it as a GUC, and use the check hook to validate its format,
> > which is what we have now with s_s_names
> > - Rely on SIGHUP to maintain an in-memory image of the quorum/priority
> > sync state
> > - Have the possibility to define group labels in this JSON blob, and
> > be able to use those labels in a quorum or priority sync definition.
> > - For backward-compatibility, use for example s_s_names = 'json' to
> > switch to the new system.
>
> Personally, I think we're going to find that using JSON for this
> rather than a custom syntax makes the configuration strings two or
> three times as long for

They may well be 2-3 times as long. Why is that a negative?

> no discernable benefit.
>

Benefits:
* More readable
* Easy to validate
* No additional code required in the server to support this syntax (so no
bugs)
* Developers will immediately understand the format
* Easy to programmatically manipulate in a range of languages

--
Simon Riggs http://www.2ndQuadrant.com/
<http://www.2ndquadrant.com/>
PostgreSQL Development, 24x7 Support, Remote DBA, Training & Services

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Robert Haas 2015-07-16 17:40:42 Re: Support for N synchronous standby servers - take 2
Previous Message Robert Haas 2015-07-16 17:27:53 Re: Support for N synchronous standby servers - take 2