Christian German
Christian German

Reputation: 166

Couchbase Sync Gateway business logic

I'm currently working on an architecture with an offline mobile client and a database server.

I was thinking about using the sync-gateway component from couchbase, hence, couchbase as a server db and pouchdb as a client db. The business logic is quite complex, though and as far as I understand, synchronization filtering, data validation and authorization is made through the gateway configuration. Is this a good idea or couchbase synchronization capabilities are preferred for simpler logics and I should stick to a more Spring Rest API and fill the local indexDB manually.

Upvotes: 1

Views: 127

Answers (1)

rajagp
rajagp

Reputation: 1443

Couchbase Sync Gateway is used in very large enterprise grade deployments of varying complexity and scale so that shouldn't be an issue. The decision you would need to make is whether you need sync or you are looking for a simple request-response approach (that's better suited for connected environments). FWIW, Sync Gateway also supports a REST interface - so you can use indexedDB requesting data via the REST interface as well.

You mention offline mobile client so why are you not using couchbase lite as the embedded database? Is this a PWA? The synchronization protocol between Couchbase lite and Sync Gateway is more performant and advanced compared to the couchDB based approach used between the likes of PouchDB and Sync Gateway.

Upvotes: 0

Related Questions