Skip to content
This repository was archived by the owner on Apr 5, 2018. It is now read-only.

Conversation

@jvdweerthof
Copy link

couch-replicator-api.js:

  • Add doc_id parameter to CouchReplicatorApi constructor (May be omitted for backward compatibility)
  • Add automatic selection of doc_id or db to get, put, del functions (doc_id takes preference over db)
  • Add JSDoc for CouchReplicatorApi constructor

status.js:

  • Add doc_id parameter to status function (May be omitted for backward compatibility)
  • Change filter to match on doc_id if set (instead of target)

Example usage:

const CouchReplicator = require('couch-replicator-api')

    , replicator = new CouchReplicator(
          'http://npm.nodejs.org.au:5984'
        , 'user'
        , 'pass'
        , 'registry',
        , 'registry_to_127.0.0.1:5984'
      )

couch-replicator-api.js:
- Add doc_id parameter to CouchReplicatorApi constructor (May be omitted for backward compatibility)
- Add automatic selection of doc_id or db to get, put, del functions (doc_id takes preference over db)
- Add JSDoc for CouchReplicatorApi constructor

status.js:
- Add doc_id parameter to status function (May be omitted for backward compatibility)
- Change filter to match on doc_id if set (instead of target)

Example usage:
```js
const CouchReplicator = require('couch-replicator-api')

    , replicator = new CouchReplicator(
          'http://npm.nodejs.org.au:5984'
        , 'user'
        , 'pass'
        , 'registry',
        , 'registry_to_127.0.0.1:5984'
      )
```
@jvdweerthof
Copy link
Author

In our projects we often use replication id's/names that are different from the database name, mainly to identify to which couch server the db is replicated. I'm aware that we are not alone in this, so this change should benefit a wider audience than just our project.

jvdweerthof pushed a commit to jvdweerthof/npm-replicator-monitor that referenced this pull request Jul 13, 2015
**Note:** This commit _requires_ an update of the [node-couch-replicator-api](https://github.com/rvagg/node-couch-replicator-api/) package, see [Pull Request #2](rvagg/archived-node-couch-replicator-api#2). Without this update the code will run, but the added functionality will not be effective.

Changes:
- Add optional parameter `"doc_id"` to specify a specific _replicator id
jvdweerthof pushed a commit to jvdweerthof/npm-replicator-monitor that referenced this pull request Jul 13, 2015
**Note:** This commit _requires_ an update of the [node-couch-replicator-api](https://github.com/rvagg/node-couch-replicator-api/) package, see [Pull Request](rvagg/archived-node-couch-replicator-api#2). Without this update the code will run, but the added functionality will not be effective.

Changes:
- Add optional parameter `"doc_id"` to specify a specific _replicator id
jvdweerthof pushed a commit to jvdweerthof/npm-replicator-monitor that referenced this pull request Jul 13, 2015
**Note:** This commit _requires_ an update of the [node-couch-replicator-api](https://github.com/rvagg/node-couch-replicator-api/) package, see [Pull Request](rvagg/archived-node-couch-replicator-api#2). Without this update the code will run, but the added functionality will not be effective.

Changes:
- Add optional parameter `"doc_id"` to specify a specific _replicator id
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant