couchdb-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Robert Newson <>
Subject Re: Replication and sequence id question
Date Tue, 16 Apr 2013 11:23:38 GMT
Hi Paolo,

The checkpoint is stored in the database at source and target, so
couchdb will fail to find that document on server B and so it will
start from update sequence 0.


On 16 April 2013 10:06, Paolo Negri <> wrote:
> Hi Robert
> On Tue, Apr 16, 2013 at 10:05 AM, Robert Newson <> wrote:
>> Hi Paolo,
>> No, couchdb (and touchdb) will be just fine if you fail over to a
>> different server. What will happen is that the replication from server
>> B to your mobile client will start from update sequence 0 (as you will
>> have no previous checkpoint).
> I'm wondering what happens if the fallback is not explicit to the
> client let's say I have the database exposed under
> and under this url usually respond
> server A but after the failover requests are instead forwarded
> internally to server B won't the mobile client be looking for the
> checkpoint of server A and be confused about the fact of being talking
> with server B instead?
>> The replication process will then check
>> whether each update on server B is on your client already. If the A to
>> B replication is still running, then the majority of updates you get
>> from server B will already be present on your mobile device. Any that
>> are missing will be replicated.
>> You can freely replicate from multiple servers to your mobile client, it works.
>> B.
>> On 16 April 2013 08:43, Paolo Negri <> wrote:
>>> Dear list
>>> I have a question related to couchdb replication, let me walk you
>>> through the scenario
>>> I have 2 servers server A and server B
>>> on both A and B I'm running couchdb
>>> B is configured to replicate all dbs from A
>>> I also have one mobile client that uses touchdb to sync data with one
>>> database on server A
>>> At some point server A breaks and then the mobile client can't reach A
>>> and then will fallback to B
>>> What happens in terms of syncing? will the mobile client be confused
>>> by the fact that the database on server B doesn't share sequence
>>> numbers with the same database in A?
>>> Thanks for your help,
>>> Paolo

View raw message