I am trying to replicate documents to CB Lite with a pull replication on Android.
I am creating documents on the server with the NodeJS Couchbase SDK. When I create a document I am including a channels property. Looks like this:
{
…
“channels”: [ “pulluserchannel” ]
}
My sync gateway user looks like this (from curl -k https://127.0.0.1:4985/btleperftest/_user/pulluser ):
{
“name”:“pulluser”,
“admin_channels”:[“pulluserchannel”],
“all_channels”:["!",“pulluserchannel”]
}
It never replicates a single document.
Should this work ?
Or do I have to create the document though the sync gateway instead of creating it on the server directly ?
I think you should create the document though the sync gateway,and do not creating it on the server directly.because after create the document though the sync gateway, sync gateway will do some compute and add _sync property into document for data route and acl.