Redis native module to add support for compare and swap
CAS key current_value new_value
Compare the value of a key and set if the passed current value hasn't changed
Returns number of modified keys
127.0.0.1:6379> set foo bar
OK
127.0.0.1:6379> cas foo bar baz
(integer) 1
127.0.0.1:6379> cas foo bar baz
(integer) 0
task load-redis-module