Copied from http://www.couchbase.com/communities/q-and-a/serialisingdeserialising-cas, because I'm noticing that there's very little activity there unfortunately!
Using the Nodejs Couchbase API, I'm noticing that I have to use the exact cas object returned from a "get" operation as the cas option in a subsequent "set" operation. If I make a copy of the cas object e.g. cas = JSON.parse(JSON.stringify(cas)) then the "set" call fails with keyAlreadyExists. So the question is, how do I manage to implement cas update conflict prevention when the object retrieved by "get" required serialisation before it is modified, and subsequently "set"? (In my case this is because the document modification occurs on a remote client communicating with the server over http REST interface, which surely must be a very common use case?) Cheers, Steven -- You received this message because you are subscribed to the Google Groups "Couchbase" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. For more options, visit https://groups.google.com/d/optout.
