Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP

Loading…

Allow replication between databases rather than server #89

Closed
bmeck opened this Issue · 2 comments

2 participants

@bmeck

Right now we can replicate using:

nano.db.replicate(string, string, ...)

When given a nano Database objects this causes difficulties when wanting to replicate with something like:

var source = require('nano')('.../a')
var target = require('nano')('.../b')

In order to replicate right now, we must deconstruct a new Database object, then attempt to parse the configs properly.

Is there a reason we cannot replicate simply between source and target in the second example, and/or allow a db to reference it's server?

source.replicate(target, ...);

or

source.server.replicate(source, target);
@dscape
Owner

Is this not what you are looking for?

https://github.com/dscape/nano/blob/master/nano.js#L755

@dscape dscape closed this in 158112f
@dscape
Owner

Don't worry I got it. Landed in nano@3.0.8

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Something went wrong with that request. Please try again.