How to skip replication of Blobs above 5MB?

I know Blobs above 20MB are not replicated, but I want to do this with 5MB and above.

can you use push/pull filter to check the size?

1 Like

I want to replicate the documents except the blobs.

It’s not possible to only skip blob and send remaining doc. You could skip the whole document

But it’s possible to skip Blobs above 20MB, that’s the default right? Seems trivial to change the minimum size.

Working with Blobs — Data Model | Couchbase Docs

On Couchbase Lite, blobs can be arbitrarily large, and are only read on demand, not when you load a Document object. On Sync Gateway, the maximum content size is 20 MB per blob. If a document’s blob is over 20 MB, the document will be replicated but not the blob.

The 20MB limit is the maximum size of documents (that includes blobs which are binary documents ) that is allowed on Couchbase server and it is enforced on server side. If you don’t want to sync blobs to server, save it as a local file on your device and only include file URL of that blob data within your document. Of course since you are not syncing the blob, I take it that you don’t expect that blob to be updated by anyone else and that you are OK if the device crashes for instance and you lose the blobs that are locally saved.