http://neopythonic.blogspot.in/2011/08/compare-and-set-in-memcache.html, 
GVR talks about a use case of a simple counter.

Generalizing that, 1) would it be fine to say you could use CAS when you 
need to modifying the data according to the latest state? For example 
counter, appending a list, modifying a dictionary etc ..?

3) I could *retry* memcache.cas(key, value) where value is a static data, 
but I think it doesn't serve any more purpose than memcache.set(key, value) 
right?

I have seen some snippets that try to overcome memcache.set misses by 
implementing a memcache.cas. It sounds logical because it is done in a 
*retry* but what is not logical is that it *fails* if the value has 
*changed* already and not if a *miss* happened, am I right?

4) However I wonder if it is possible to use memcache.cas for overcoming 
set misses as a side effect? A miss happened, client returned a failure, 
retry happened it worked.

And I wonder 5) if there is a better way to handle set failures 6) does 
memcache.add also have set failure possibilities.

-- 
This e-mail message (including any attachments) may contain information 
that is confidential, protected by the attorney-client or other applicable 
privileges, or otherwise comprising non-public information. This message is 
intended to be conveyed only to the designated recipient(s). If you have 
any reason to believe you are not an intended recipient of this message, 
please notify the sender by replying to this message and then deleting it 
from your system. Any use, dissemination, distribution, or reproduction of 
this message by unintended recipients is not authorized and may be unlawful.

-- 

--- 
You received this message because you are subscribed to the Google Groups 
"memcached" 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.

Reply via email to