[Date Prev][Date Next]
Comments on replication consistency models
- To: openldap-devel@OpenLDAP.org
- Subject: Comments on replication consistency models
- From: Howard Chu <email@example.com>
- Date: Fri, 15 Dec 2006 17:43:55 -0800
- User-agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.9a1) Gecko/20061211 Netscape/7.2 (ax) Firefox/1.5 SeaMonkey/1.5a
The Fedora folks have some comments defending their support of
multi-master replication here
For the most part there's nothing noteworthy. Just wanted to address
their point "There is no way for any LDAP loosely coupled replication to
guarantee "read your writes" consistency." In fact, as we've discussed
here a few times in the past, this not true.
We can guarantee "read your writes" consistency with the help of a
tweaked chaining overlay. I.e.,
1) the client issues a write request to a slave
2) the slave chains the request to the master
3) when the chained write succeeds, the slave performs the write locally
4) the response is returned to the client
Assuming the client continues talking to the same slave, it will always
see consistent data.
It's a form of two-phase commit but a very special case. Since it only
requires waiting for one remote operation to succeed it's a lot more
efficient than managing generalized N-server two-phase commit.
As a further optimization, the chained request can carry a control
"don't loop back to me" telling the master not to propagate this update
back to the initiating slave. It only saves a small bit of bandwidth,
since with syncrepl, the subsequent redundant update would be idempotent.
-- Howard Chu
Chief Architect, Symas Corp. http://www.symas.com
Director, Highland Sun http://highlandsun.com/hyc
OpenLDAP Core Team http://www.openldap.org/project/