Over a million developers have joined DZone.
{{announcement.body}}
{{announcement.title}}

Couchbase Mobile: Multi-Master vs. Client-Server Models

DZone's Guide to

Couchbase Mobile: Multi-Master vs. Client-Server Models

· Cloud Zone
Free Resource

Site24x7 - Full stack It Infrastructure Monitoring from the cloud. Sign up for free trial.

The syncing of mobile data is an important issue, ranging from clean and reliable (Pocket, for example) to spotty and erratic (Facebook, for example). In this recent article, Adam Wiggins of Wandering CTO discusses the Clue engineering team's solution to syncing mobile data: Couchbase Mobile.

The appeal of Couchbase Mobile, according to Wiggins, is the multi-master model, as opposed to the more common client-server model. With the multi-master model, your data is replicated in multiple locations - both on your device and on the backend - which gets around the problem of network connectivity. He describes the difference as follows:

The lightbulb moment for me came by thinking of the difference between client-server vs master-master syncing as the difference between Subversion and Git.

With Subversion, you can’t commit changes unless you can talk to the server. Unavailable or intermittent network connectivity blocks your ability to work. Git (and other DVCSes), on the other hand, store a copy of the revision control database (as the .git directory) with every repository. So you can work continuously without network, committing as you go. Git pull & push do a sync.

Wiggins makes a persuasive and concise argument in favor of the multi-master model, but poses a number of questions as well. For example:

  • How do you handle multi-tenancy?
  • How do you manage/authenticate users?
  • Where would backend logic run?

For more details on the Clue engineering team's work with Couchbase Mobile, as well as the conclusions they came to, check out Wiggins' full post.

Site24x7 - Full stack It Infrastructure Monitoring from the cloud. Sign up for free trial.

Topics:

Opinions expressed by DZone contributors are their own.

THE DZONE NEWSLETTER

Dev Resources & Solutions Straight to Your Inbox

Thanks for subscribing!

Awesome! Check your inbox to verify your email so you can start receiving the latest in tech news and resources.

X

{{ parent.title || parent.header.title}}

{{ parent.tldr }}

{{ parent.urlSource.name }}