Re: Support for N synchronous standby servers - take 2

From: Beena Emerson <memissemerson(at)gmail(dot)com>
To: pgsql-hackers(at)postgresql(dot)org
Subject: Re: Support for N synchronous standby servers - take 2
Date: 2015-07-30 05:16:51
Message-ID: 1438233411014-5860197.post@n5.nabble.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

Hello,

Just looking at how the 2 differnt methods can be used to set the s_s_names
value.

1. For a simple case where quorum is required for a single group the JSON
could be:

{
"sync_standby_names":
{
"quorum":2,
"nodes":
[ "node1","node2","node3" ]
}
}

or

{
"sync_standby_names":
{
"quorum":2,
"group": "cluster1"
},
"groups":
{
"cluster1":["node1","node2","node3"]
}
}

Language:
2(node1, node2, node3)

2. For having quorum between different groups and node:
{
"sync_standby_names":
{
"quorum":2,
"nodes":
[
{"priority":1,"nodes":["node0"]},
{"quorum":2,"group": "cluster1"}
]
},
"groups":
{
"cluster1":["node1","node2","node3"]
}
}

or
{
"sync_standby_names":
{
"quorum":2,
"nodes":
[
{"priority":1,"group": "cluster2"},
{"quorum":2,"group": "cluster1"}
]
},
"groups":
{
"cluster1":["node1","node2","node3"],
"cluster2":["node0"]
}
}

Language:
2 (node0, cluster1: 2(node1, node2, node3))

Since there will not be many nesting and grouping, I still prefer new
language to JSON.
I understand one can easily, modify/add groups in JSON using in built
functions but I think changes will not be done too often.

-----
Beena Emerson

--
View this message in context: http://postgresql.nabble.com/Support-for-N-synchronous-standby-servers-take-2-tp5849384p5860197.html
Sent from the PostgreSQL - hackers mailing list archive at Nabble.com.

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Piotr Stefaniak 2015-07-30 05:28:24 Division by zero in selfuncs.c:estimate_hash_bucketsize()
Previous Message Joe Conway 2015-07-30 04:41:29 Re: dblink: add polymorphic functions.