arthurnn / memcached

A Ruby interface to the libmemcached C client
Academic Free License v3.0
432 stars 127 forks source link

Add CAS support #197

Open casperisfine opened 3 years ago

casperisfine commented 3 years ago

It is fairly basic for now, so I'm looking for feedback before all.

Since libmemcached requires to use the mget API to get the CAS token back, I implemented it as a "cas_multi".

I'm not too sure about the return value, I tried to return false when any of the values returned by the block wouldn't not be stored.

@dylanahsmith thougths?

arthurnn commented 3 years ago

❤️