0

I read here that Cassandra has no concept of Isolation Levels and that you need to use External Locking(say Zookeeper) to enforce any kind of locking, which will magnify the latency manyfold.

I wonder, without the concept of Isolation Levels, how would vanilla Cassandra be useful?(what kind of applications can make use of vanilla Cassandra without external locking?)

Aren't Consensus algorithms best used infrequently (eg: for topology changes, membership updates etc) and isn't it an anti-pattern to run consensus for every write request especially when the RPS is way too high for writes?

EDIT: Added note on consensus at scale

1

1 Answer 1

1

This post appears to be a variation of your other question which I've also responded to.

I explained in the other post that Cassandra is designed for high velocity concurrent throughput at internet scale. It is designed to serve millions and millions of reads per second and accept writes from multiple clients.

It was originally intended to solve problems at internet scale that Facebook had and so do a lot of internet giants. Its main purpose was to serve millions of concurrent requests at internet scale.

You're referring to an answer from a post that's from 15 years ago and things have changed a lot since.

To directly respond to your question, Cassandra is useful in all kinds of use cases including eCommerce, fraud detection, personalisation, banking and finance, and so on. Almost all of Fortune 500 companies use Cassandra and so do most of the tech giants around the world including Apple, eBay, Microsoft, Netflix and more.

I can pretty much guarantee that you are using technology that is powered by Cassandra every single day even if you don't know about it. Cheers!

UPDATE - The consensus locking does not block all writes -- only those which require consensus. Also, Cassandra only blocks the specific partition that requires isolation, not the whole table because that would be impossible to do that.

It is easy to imagine all writes being blocked in RDBMS because again of the shared disks/storage. But in Cassandra where every single node is its own database instance with nothing shared, you cannot lock up a whole table that is distributed across nodes. Imagine if you had a cluster that had hundreds or even thousands of nodes -- locking the table across DCs across the globe is inconceivable.

3
  • Hi @Erick. I've edited my question to add a note regarding consensus. Even with Accord, wouldn't running consensus for every write request turn out really bad for performance ?
    – D.B.K
    Commented Jun 21 at 4:57
  • I've updated my answer with a response to your follow up question. Cheers! Commented Jun 21 at 5:07
  • Thanks for relating it to RDBMS locking. Can you elaborate why LWTs block only other LWTs and not normal quorum writes? wouldn't a quorum write have the potential to interrupt (and disrupt) a batched LWT which would take some time to arrive at consensus and then apply those writes? In the midst of the consensus algorithm, if the quorum write updates the value that was being read by the LWT, it would be diffcult to reason about the behavior, correct? tldr; a question on isolation between LWT and a quorum write
    – D.B.K
    Commented Jun 21 at 5:22

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