You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
This library, will return true or false for all calls to EXISTS. However, this is not consistent with the return value for core redis. According to the documentation:
Return value
Integer reply, specifically:
1 if the key exists.
0 if the key does not exist.
Since Redis 3.0.3 the command accepts a variable number of keys and the return value is generalized:
The number of keys existing among the ones specified as arguments. Keys mentioned multiple times and existing are counted multiple times.
When passing multiple keys, there is no way to determine how many of the keys exist.
The text was updated successfully, but these errors were encountered:
Even though, SISMEMBER returns a boolean in this library, but an integer in core redis, I don't think the issue is particularly important since SISMEMBER only takes a single value as an argument, the return values are only 1 or 0. So, no data is lost.
aeisenberg
pushed a commit
to GanchrowScientific/gs-lua-unit
that referenced
this issue
Feb 16, 2018
Returns 1 if key exists or 0 otherwise.
Not exactly correct since calling exists with multiple should return
a number greater than 1 if multiple keys exists, but there is no
way of determining this with the current library. See:
nrk/redis-lua#54
Change-Id: I5b0f63aba26111e0a26e50971520c482d0d9da0b
Reviewed-on: http://gerrit.ganchrow.com:8080/4781
Reviewed-by: Andrew Eisenberg <[email protected]>
Tested-by: Andrew Eisenberg <[email protected]>
This library, will return true or false for all calls to EXISTS. However, this is not consistent with the return value for core redis. According to the documentation:
When passing multiple keys, there is no way to determine how many of the keys exist.
The text was updated successfully, but these errors were encountered: