|
options:- delta [Fixnum] Amount to incr/decr, default is 1, can be up to 64 bits
- :create [true, false] If set to true, if key doesn’t exist, initializes to zero but doesn’t increment, can be combined with :initial
- :initial [Fixnum, Unsigned Integer] Sets initial value if key doesn’t exist, doesn’t increment the initial value!
- :extended [true, false] Returns [value, cas] tuple instead of just value
- :ttl [Fixnum, Integer] Sets TTL, doesn’t alter existing TTL, will only be applied to a new item created via :create and/or :initial
复制代码 Touch Operations
Reset the TTL expiration on one or more keys explicitly with the touch command, can also be done with a get command.- client.touch(key, ttl)
- client.touch({“key1”=> ttl1, “key2” => ttl2})
复制代码 |
|