Created
March 17, 2011 23:09
-
-
Save cararemixed/875335 to your computer and use it in GitHub Desktop.
Just some ideas for making Redis MULTI/EXEC much more powerful
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
WATCH key Watch should still work | |
[regular ops] ... | |
MULTI Multi call to create more interesting operations | |
SADD foo bar Basic mutation. No interesting result. | |
SMEMBERS foo Pulls members of the set... usually returned to client but not here | |
SORT @2 DESC LIMIT 10 GET qux_* GET # Does a sort on the 2nd multi command's result | |
COPY @3 stuff Copy one key to another. One way to save multi results directly | |
EXEC @3 Executes but only returns 3rd bulk result |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment