cassandra-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Brandon Williams <>
Subject Re: create only - no update
Date Tue, 15 Dec 2009 23:34:56 GMT
On Tue, Dec 15, 2009 at 5:19 PM, Brian Burruss <> wrote:

> can the cassandra client (java specifically) specify that a particular
> "put" should be "create only, do not update"?  If the value already exists
> in the database, i want the put to fail.  for instance, two users want the
> exact same username, so they both do a "get" to determine if the username
> already exists, it doesn't, so they create.  the last one to create wins,
> correct?

Correct.  You would need to implement a locking mechanism such as Zookeeper
 in your application to get around this.


View raw message