cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Sylvain Lebresne <>
Subject Re: Atomic Operations in Cassandra
Date Thu, 08 Dec 2011 10:40:40 GMT
On Thu, Dec 8, 2011 at 12:57 AM, Christof Bornhoevd
<> wrote:
> Hi All,
> I'm using Cassandra 1.0.3 (with Hector 0.7). What is the granularity of
> atomic read and write operations with Cassandra. I.e. is the insert or
> update of an individual column an atomic operation (in the sense that it
> either fails or persists completely), or is the insert or update of an
> entire row in a ColumnFamily atomic?
> Similarly, if I read multiple columns of the same row, could the read
> operation interfere with a concurrent write operation on these same columns
> in a way that I might see some old and some new column values?

Writes under the same row key are atomic (even across column families) in the
sense that they are either all persisted or none are. Note however that it is
possible for a insertion to fail for the client (say you get a
TimeoutException) but
for the insertion to still be persisted.
There is however no isolation currently. It is possible for a read to
see a state
where only part of an insertion (even within the same row key) has been applied.
(CASSANDRA-2893 is open to try to add isolation).


> Cheers and thanks a lot for any kind help on this!
> Chris

View raw message