Cassandra for storing payment information?

Specific to your questions about availability and EC2 ... As Theodore wrote, the consistency level in Cassandra will dictate how "safe" the data is. The problems you'll face is how to ensure the data is getting to Cassandra, fulfilling your Transaction goals and is being saved appropriately.

Specific to your questions about availability and EC2 ... As Theodore wrote, the consistency level in Cassandra will dictate how "safe" the data is. The problems you'll face is how to ensure the data is getting to Cassandra, fulfilling your Transaction goals and is being saved appropriately. There are some good threads about transactions and solving this problem on the Apache Cassandra User's mailing list.

Cassandra on it's own is not suitable for transactions: Cassandra - transaction support To get around this, you need "something" that can leverage Cassandra as a data store that manages the transactions above the data tier. How to integrate cassandra with zookeeper to support transactions Cages: http://code.google.com/p/cages/ 'Locking and transactions over Cassandra using Cages': http://ria101.wordpress.com/2010/05/12/locking-and-transactions-over-cassandra-using-cages/ There is a section called "Transactions for Cassandra" for more information Summary ... You cannot guarantee financial transactions with Cassandra alone.

There are lots of different ways to define consistency. If by "maximal consistent transaction", you mean reading and writing at ConsistencyLevel ALL, then that will provide consistency in sense that your reads will never return an out-of-date value, and durability in the sense that your writes will be stored on all nodes before returning. That's not the same as transactions, however.

Cassandra does not support transactions. It doesn't provide consistency between different rows, as MySQL does. For example, suppose you add an item to the shopping basket, and update the total cost in the cart.

Individually, each operation will be stored consistently and durably. However, there may be a window of time in which you can see one change but not the other. In a relational database, you can group them into a transaction so that you can only see both, or neither.As far as safety goes, Cassandra stores all your writes to disk in a commit log before it does anything else, in the same way that relational databases use transaction logs.

So it is just as safe with regard to system crashes. With regards to node failures, if you write at CL. ALL, then you will never lose data as long as one node in each replica set survives.

With regard to disk failure, that is a matter for your underlying hardware setup, e.g. RAID.

Thanks for providing a lot of clear information. To remedy the lack of transactions can the following be done: I create a cassandra table called "locks". When I want to perform a transaction on the database, I add the uuid representing the rows I will write at to the locks table.

After I am done writing the rows of interest with QUORUM, I delete the uuids from the locks table. If an independent query is tried in the mean time, it will first check to see if the relevant uuids are present in the locks tables, and will be disallowed if they are. Will that permit transactions?

Very slow ones only? – Alexandre H. Tremblay Oct 21 at 16:50 Unfortunately this is still prone to a race condition in the following way: 1.

Client A checks the lock table and finds nothing. 2. Client A reads the shopping basket.3.

Client B writes to the lock table. 4. Client B updates the shopping basket and the total cost.5.

Client B clears the locks.6. Client A reads the total cost, which is now inconsistent with the shopping basket read earlier. This problem cannot be solved without using stronger distributed protocols such as that provided by Zookeeper (mentioned by @sdolgy) – Theodore Hong Oct 24 at 15:24 I think you skipped one of the steps.

The initial steps would instead be: 1. Client A checks the lock table and finds nothing.2. Client A inserts a lock on each item it intends to read or write to.3.

Client A reads the shopping basket.3. Client B checks the lock table and finds a lock on the items it is interested in therefore it stops.4. Client A finishes his operations.

– Alexandre H. Tremblay Oct 24 at 15:56.

I cant really gove you an answer,but what I can give you is a way to a solution, that is you have to find the anglde that you relate to or peaks your interest. A good paper is one that people get drawn into because it reaches them ln some way.As for me WW11 to me, I think of the holocaust and the effect it had on the survivors, their families and those who stood by and did nothing until it was too late.

Related Questions