Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Confused with CouchDB and Couchbase

I'm investigating CouchDB and Couchbase as I am looking for a DB solution for a web application that I will eventually be able to make into a native Android/iOS app as well. From what I understand, CouchDB/Couchbase excel at being able to use the DB offline and have it synchronize as soon as the connection is restored.

I further understand that CouchDB and Couchbase are 2 distinct products from 2 different organizations - CouchDB is from Apache and Couchbase is from Couchbase. There is a great response in SO here explaining some of the differences.

Couchbase has Couchbase-Lite-Android and similar for iOS as native embedded DBs for mobile apps which sync with Couchbase server.

Where I get lost is when I try to find the CouchDB equivalent. Everything points to TouchDB which then says it is no longer actively developed and instead points to Couchbase-Lite-Android as the project that has superceeded it. But does Couchbase-List-Android/iOS sync with CouchDB or just Couchbase? According to the Wiki, it indicates that it can sync with CouchDB, but it is a secondary backend which receives lower priority and/or bug fixes.

So then what are the embedded/mobile versions of CouchDB that should be used for Android/iOS?

like image 571
Eric B. Avatar asked Sep 29 '22 22:09

Eric B.


1 Answers

It's "Couchbase Lite".

I've answered a similar question/confusion over here. TouchDB was built to be an Apache-CouchDB compatible database engine suitable for embedding into mobile/desktop apps. The compatible factor here is CouchDB's replication protocol & NoSQL data model.

In a process to offer mobile synchronization as a feature of Couchbase Server, they altered and renamed TouchDB as Couchbase Lite and also, built Sync Gateway to act as a server-side bridge between Couchbase Server and Couchbase Lite.

But the data model & replication protocol are still the same as Apache-CouchDB and Couchbase Lite's replication is entirely compatible with CouchDB.

To conclude, Couchbase Lite <-sync-> Apache-CouchDB & Couchbase Lite <-sync-> (via Sync Gateway) Couchbase Server.

I doubt that CouchDB is a secondary backend which receives lower priority and/or bug fixes. We've been using Couchbase Lite since the days of TouchDB and IMO, Couchbase-Lite is actively developed and greatly supported.

like image 79
Ajith R Nayak Avatar answered Oct 05 '22 07:10

Ajith R Nayak