Adding new read channel for pull but not working

Couchbase Lite 1.4.4
Couchbase Server CE 6.0
Sync Gateway 15.2

Added new read channel to a document type, but unable to pull those documents using the new channel

Currently, I have a document type (known as “oiq”) that is set to 3 pre-existing channels. (e.g. “root”, branch, branch/2017)

I want to add both pre-existing oiq documents and future oiq documents to a new 4th channel (e.g. branch/oiq). Hence, I made the edits on my server using a servlet call, but the documents aren’t being pulled despite changing the channels on the app side. (e.g. Arrays.asList(“branch/oiq”); )

Alternatively, I tried renaming one of the old read channels to something else (e.g. branch/2017 to branch/000), but I was unable to pull those documents using the new channel of branch/000 too. Strangely enough, branch/2017 still works despite the renaming.

Am I missing a vital process here to get things working?

I have bucket shadowing enabled so I’m not sure if this is a side effect from that.

This is my sync gateway config file.

“server”: “”,
“bucket”: “branchdb_sg”,
“username”: “”,
“password”: “”,
“users”: { “GUEST”: {“disabled”: false, “admin_channels”: ["*"] } },
“shadow”: { “server”: “”, “bucket”: “branchdb”, “username”: “”, “password”: “” },
function(doc, oldDoc)
// Check document write access


  // Set document read channels 


Solved the issue!

This “bug” was caused due to internal implementation (i.e. our dev team, so it’s not a couchbase bug/glitch) that pre-assigns roles/channels on the server, therefore any future implementation of channels should be using them instead of creating our own without running the relevant server functions first.

Thank you for updating your status. Bucket shadowing has been deprecated in Sync Gateway 1.5, having it enabled make it harder for you to self-diagnose. I am still very new to Sync Gateway, you are probably able to find out what need to be done after system got upgraded to bucket shadowing deprecated version.