1

As NoSQL DBs always prefer BASE over ACID.

Everyone always says that you can't have ACID when you are working with a NoSQL DBs.

For example, we have MongoDB (a popular NoSQL DB), which is hosted within a single server. No replicas. If the client app updates a document, strong consistency should take place.

(Just curious, not expert)

1

Yes, a write to a single instance, distributed database will be immediately consistent. You likely still won't have ACID, as each NoSQL variant has its own ways of handling (or not) atomicity.

Although, I have to wonder what the goal would be here. The main feature of a NoSQL database is its ability to support partition tolerance...which is lost in a single instance configuration. I can't think of many scenarios like that where I wouldn't just run Postgres.

0

Yes that's correct, inherently you end up with strong consistency because the use case is a single node server as opposed to a cluster.

Conversely there are RDBMS that offer consistency across multi-node clusters or quasi-hybrids of the BASE and ACID principals nowadays too.

Everything is fair game, there's a lot of blurred lines, and using NoSQL in a single server is pretty normal and will automatically offer consistency since there's nothing to replicate to.

0

What "Everyone" says isn't true!

A related issue was discussed on this forum recently ("If NoSQL stands for "Not only SQL", is SQL a subset of NoSQL?"), and in my answer, I mention 2 KV systems, one of which (RocksDB) has a subset of ACID transaction characteristics and one of which has them ALL (FoundationDB).

BTW, MongoDB is NOT fully ACID compliant - see the report from the highly respected JESPEN site here. There is further reading to be done here and here - but there is nothing to stop a system which fully supports SQL from being BASE and vice-versa...

And remember, don't believe everything a vendor tells you - they (ahem...) may be biased.

Also, don't forget that BASE is a perfectly valid strategy - for the likes of Amazon and/or Facebook where the odd cancelled order and/or lost post isn't going to be the end of the world - however, banks cannot (afford) to think like that - their systems have to be ACID - at least the ones handling financial transactions - maybe they perform their customer loyalty programmmes on a BASE system - lower machine specs and no requirement to maintain consensus/correctness leads to lower costs!

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.