Search code examples
couchbase-litecouchbase-sync-gateway

Storing data in CouchbaseServer(without metadata)


I have created data in couchabse lite db and replicated it in couchabse server , but in replication unused data is also get created on server. is there any method to store pure data (without metadata) ?

is bucket shodowing is usefull for this problem ?


Solution

  • You can use couch base server 5.1 there the extra meta data is stored in XAttrs. And the document will not have meta data inside the document. If required this meta data can be found in the X- attributes.

    For that you will need to set up the sync gateway in a manner where one sync gateway out of the cluster should have import_docs:"continuous" and all the sync gateway should have enable_shared_bucket_access:true.

    By this change in the sync gateway configuration by using sync gateway 1.5 or 2.0 you will be able implement this functionality.

    Also the good thing is, if the data is even changed directly on the server it will also flow to the devices.