You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository has been archived by the owner on Nov 5, 2018. It is now read-only.
According to http://guide.couchdb.org/draft/replication.html (and own testing), writing a replication document to "_replicate" will enable replication only for the current server session, but after a server restart it will not enable it again.
CouchDB developers in their infinite wisdom handle requests to "_replicator" differently from requests to "_replicate".
While requests to "_replicate" replied with a full response, requests to "_replicator" reply with a partial response and need to be polled until the replication is done. Working on implementing that.
After a few tries, I came to the conclusion that this requires at least two different methods. The reason is that replication will be scheduled after a write to "_replicator" and couchdb will handle the status internally. At some point in time the replication will finish (either successfully or with error), but there is no way to know when.
The idea behind this is to allow for a fully asynchronous API that can monitor the status of the replication without having to wait on it. This is especially important in large replication where the time involved in replication might be measured in several minutes, hours or even days!
So I have come up with three methods:
enableReplication: Starts the replication from a given db to a target db.
queryReplication: Queries the state of the replication at that time.
disableReplication: Stops the replication process.
According to http://guide.couchdb.org/draft/replication.html (and own testing), writing a replication document to "_replicate" will enable replication only for the current server session, but after a server restart it will not enable it again.
Relates to #290
The text was updated successfully, but these errors were encountered: