CAS Delete support in any Python memcached client?

28 views
Skip to first unread message

mum...@gmail.com

unread,
Dec 12, 2013, 4:48:10 PM12/12/13
to memc...@googlegroups.com
Hi all,

Just tried (and failed) to find any Python client with support for the new-ish CAS operations on the binary protocol (i.e. CAS delete etc.). Does anyone know of one - or have any plans for one? Or is there a fork of the C libmemcached library which supports it?

dormando

unread,
Dec 14, 2013, 8:42:53 PM12/14/13
to memc...@googlegroups.com
The C libmemcached library *should* support it already. I don't know why
any of the python wrappers wouldn't :/ Have you contacted the author of
one?

James Haggerty

unread,
Dec 15, 2013, 6:02:36 AM12/15/13
to memc...@googlegroups.com
A brief squiz at the delete function seems to suggest it doesn't:

http://bazaar.launchpad.net/~tangent-trunk/libmemcached/1.2/view/head:/libmemcached/delete.cc

Am I missing something?

(the most popular native Python clients use the text protocol, so can only do cas set; the others use libmemcached, which doesn't seem to support it)



--

---
You received this message because you are subscribed to a topic in the Google Groups "memcached" group.
To unsubscribe from this topic, visit https://groups.google.com/d/topic/memcached/eWs-mbyQuew/unsubscribe.
To unsubscribe from this group and all its topics, send an email to memcached+...@googlegroups.com.
For more options, visit https://groups.google.com/groups/opt_out.

Hirotaka Yamamoto

unread,
Dec 16, 2013, 1:56:27 AM12/16/13
to memc...@googlegroups.com
In fact, the binary protocol specifies CAS operations only for Set/Add/Replace.
Delete with CAS seems unspecified.

James Haggerty

unread,
Dec 16, 2013, 3:31:24 AM12/16/13
to memc...@googlegroups.com
My reading of the binary protocol is that there is space for CAS but the behaviour is unspecified.

But the source certainly seems to support it:
https://github.com/memcached/memcached/blob/master/memcached.c#L2191

As do the release notes :)

http://code.google.com/p/memcached/wiki/ReleaseNotes140
Reply all
Reply to author
Forward
0 new messages