How does couchbase deals with network issues ?
It is possible the following:
- An upsert over an certain key happen.
- This upsert returns success
- There are some network issues, and one of the nodes suffer a restart
- The document don’t contain the the values that was upserted in step 1.
**It is possible an upsert returns success and the data be lost ? Is there any way to mitigate it? **
In Couchbase Server release 6.5 which is currently in Beta, we have a new feature for Synchronous Replication that addresses exactly the kind of problem you mention. With the new Synchronous Durability APIs you get atomic durability. So, the mutation is not acknowledged to the client until its durability criteria have been met.
There are 3 different levels of synchronous durability to choose from: replicate to majority, replicate to majority and persist to active, persist to majority.
Please give it a try and would be great to hear your feedback on this new functionality!