incubator-couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Owen Marshall <>
Subject Re: Peer-to-Peer Replication
Date Thu, 07 Apr 2011 15:37:28 GMT
On 04/06/2011 04:44 PM, Zdravko Gligic wrote:

> Does this mean that numerous replications can be set up for a single
> local CouchDB instance.  

Absolutely yes.

> If so then given a community of 100,000's of
> peers, would then a logical solution be one where each peer was
> grouped into a subset of all of the peers, by some sort of most common
> attribute - such as replicating to/from one's friends - where
> hopefully through the"friends of friends" effect, eventually everyone
> eventually gets updated?  

That seems logical, yes. Note that you will have to write
application-level routing that tries to decide how to tell CouchDB to sync.

Perhaps your app will loop over _all_dbs
( and do a push
synchronization to one/more peers. Perhaps it decides on some subset.
Either way, it's up to your app to make this happen.

> If this is even remotely the case, then what
> would be an optimal number of replications that any one local CouchDB
> should be configured with - 10's, 100's or 1000's of "friend" peers?

Again, that depends on your needs.

A lower amount of peers would mean less configuration and network
traffic, but could impose large delays before some peers synchronize
some databases.

A higher amount of peers will require much more configuration and would
increase network traffic, but would likely decrease the delay for
getting the data replicated to anyone.

You could try to find an intermediate position, such as trying to always
replicate to a "supernode", but that again depends on your needs.

Note that we are now heading into network theory land...

> However, I can not find anything that
> expands much on how one would set it up to replicate to/from a large
> pool of potential peers - hence my above questions.

This is application specific, and for good reason.

Your application-specific needs are radically different from mine.
CouchDB gives us both excellent replication, but it also makes both of
us need to fully understand *how* we want that replication to occur.

Owen Marshall
FacilityONE | (502) 805-2126

View raw message