redis-cas 1.1.0

Redis native module to add support for compare and swap
Documentation
  • Coverage
  • 50%
    2 out of 4 items documented0 out of 3 items with examples
  • Size
  • Source code size: 21.87 kB This is the summed size of all the files inside the crates.io package for this release.
  • Documentation size: 63.22 kB This is the summed size of all files generated by rustdoc for all configured targets
  • Links
  • Bajix/redis-cas
    1 0 0
  • crates.io
  • Dependencies
  • Versions
  • Owners
  • Bajix

Redis CAS (Compare and Swap)

License Cargo Documentation

Redis native module to add support for compare and swap

Syntax

CAS key current_value new_value

Compare the value of a key and set if the passed current value hasn't changed

Return

Returns number of modified keys

Example usage

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

Build and load with taskfile

task load-redis-module