Book Image

Apache Cassandra Essentials

By : Nitin Padalia
Book Image

Apache Cassandra Essentials

By: Nitin Padalia

Overview of this book

Apache Cassandra Essentials takes you step-by-step from from the basics of installation to advanced installation options and database design techniques. It gives you all the information you need to effectively design a well distributed and high performance database. You’ll get to know about the steps that are performed by a Cassandra node when you execute a read/write query, which is essential to properly maintain of a Cassandra cluster and to debug any issues. Next, you’ll discover how to integrate a Cassandra driver in your applications and perform read/write operations. Finally, you’ll learn about the various tools provided by Cassandra for serviceability aspects such as logging, metrics, backup, and recovery.
Table of Contents (14 chapters)
Apache Cassandra Essentials
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Index

Lightweight transactions


Sometimes, it could be the case that we are running two operations in parallel but want them to be executed in a serial manner, one after another. For example, if two users are registering them to the system with the same user ID at the same point in time or a user account is being updated by two different means at the same time. These tasks should run in serial in order to guarantee that the data is in the correct state for both operations; otherwise, one operation might overwrite the other's record and the first one will never know. Serialization of such task becomes hard if there are multiple nodes serving requests. In traditional database systems it was achieved by routing such requests only to one node called master node which then does serialization, however this way the cluster becomes partially functional if master node is down. In a master-less database like Cassandra it was hard to achieve as read write could go to any node. Lightweight Transaction (LWT...