couchdb-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Benoit Chesneau <bchesn...@gmail.com>
Subject Re: continuous replication questions
Date Mon, 21 Sep 2009 07:32:33 GMT
On Sun, Sep 20, 2009 at 7:39 PM, Benoit Chesneau <bchesneau@gmail.com> wrote:

>
> About that I think we need a way to replicate in real time a full
> couchdb node to another in one http connection, it will cost less
> memory (actually 193M are used for 1000 connections) and less open
> files. I don't know if it's possible by just using the current update
> events ? Or maybe by doing something like stats by adding a function ?
> For global replication I think that only having db informations in the
> feed is enough, so we get the last updated seq and if the db changed.
> Then replicator, could get the list of changes since the last updated
> seq it stored. What do you think about it ?
>

This morning I wrote a quick patch for a global db changes handler :

https://issues.apache.org/jira/secure/attachment/12420170/db_changes.patch

It manage longpolling and continuous (set feed=continuous, default is
longpoll).

Each change send a line
{"type": "typeofchange", "db": "nameof db", "seq": "updated seq in db"}

Timeout and heartbeat can also be set. Could be used in place of
current update db notifier. This patch is in dbchanges branch of my
repo :

http://bitbucket.org/benoitc/couchdb/src/b8373046523b/


- benoƮt

Mime
View raw message