Version:
Couchbase Server 4.5.1
SyncGateway 1.4.1
I have started SyncGate Way and Couchbase server service and executed the below sync config file.
{
“databases”: {
“xpense-track”: {
“server”: “http://localhost:8091”,
“bucket”: “test-bucket”,
“users”: {
“GUEST”: {“disabled”: true, “admin_channels”: },
“myuser”: {“password”: “pass”}
},
“sync”:function (doc, oldDoc) { if(doc && doc.owner){ var channelName = 'channel_'+doc.owner; channel(channelName); access(doc.owner, channelName); } }
}
}
}
Observed channel ‘!’ has been added to the user ‘myuser’ by default once executing the config file.
“all_channels”: [
“!”
]
And on creating new document via curl command for the user ‘myuser’, new channel ‘channel_myuser’ has been created.
-d '{“_id”:“uid001”,“owner”:“myuser”, “text”:“test”}
Now the available channels for myuser are ‘!’ and ‘channel_myuser’.
The documentation says, documents added to the channel ‘!’ will be visible to any user, but iam interested only with private channels.
Does it is the SG feature that all users will have public (!) channel by default along with other channels? or can we restrict creating channel ‘!’ by default.