loopback-rest-connector-syncgateway
Component for connecting to couchbase's sync gateway
Last updated 3 years ago by minho814 .
ISC · Repository · Bugs · Original npm · Tarball · package.json
$ cnpm install loopback-rest-connector-syncgateway 
SYNC missed versions from official npm registry.

loopback-rest-connector-syncgateway

Note: For SyncGateway 1.2

Installation

npm i --save loopback-rest-connector-syncgateway

SyncGateway Public REST API reference: http://developer.couchbase.com/documentation/mobile/1.2/develop/references/sync-gateway/rest-api/index.html

Adding rest connector to an api:

  1. Add to component-config:
"loopback-rest-connector-syncgateway": {
  "bucket": process.env.COUCHBASE_BUCKET,
  "url": process.env.SYNC_GATEWAY_URL,
  "models": [
    {
      "<someModelName>": [ "databases", "documents-and-attachments" ]
    }
  ]
}
  1. Change the model datasource to transient in model-config.json

  2. The name of your bucket will be set with your COUCHBASE_BUCKET environment variable ex. COUCHBASE_BUCKET=somebucket

  3. Add a SYNC_GATEWAY_URL environment variable which will be the url:port ex. SYNC_GATEWAY_URL=192.168.99.100:4984 (4984 is the default port for sync gateway)

Available remote methods include: databases documents-and-attachments local-documents authentications

Current Tags

  • 0.9.1                                ...           latest (3 years ago)

4 Versions

  • 0.9.1                                ...           3 years ago
  • 0.9.0                                ...           3 years ago
  • 0.3.0                                ...           3 years ago
  • 0.2.0                                ...           3 years ago
Maintainers (2)
Downloads
Today 0
This Week 0
This Month 0
Last Day 0
Last Week 0
Last Month 5
Dependencies (15)
Dev Dependencies (11)
Dependents (0)
None

Copyright 2014 - 2016 © taobao.org |