- 30 Oct, 2013 6 commits
- 25 Oct, 2013 2 commits
-
-
antirez authored
-
Pieter Noordhuis authored
-
- 30 Aug, 2013 1 commit
-
-
antirez authored
-
- 29 Aug, 2013 1 commit
-
-
antirez authored
-
- 22 Jul, 2013 1 commit
-
-
antirez authored
-
- 19 Jun, 2013 1 commit
-
-
antirez authored
-
- 28 Mar, 2013 3 commits
- 27 Mar, 2013 2 commits
- 25 Mar, 2013 1 commit
-
-
antirez authored
Fixes #621.
-
- 12 Feb, 2013 2 commits
- 28 Jan, 2013 1 commit
-
-
antirez authored
-
- 21 Jan, 2013 1 commit
-
-
antirez authored
UNSUBSCRIBE and PUNSUBSCRIBE commands are designed to mass-unsubscribe the client respectively all the channels and patters if called without arguments. However when these functions are called without arguments, but there are no channels or patters we are subscribed to, the old behavior was to don't reply at all. This behavior is broken, as every command should always reply. Also it is possible that we are no longer subscribed to a channels but we are subscribed to patters or the other way around, and the client should be notified with the correct number of subscriptions. Also it is not pretty that sometimes we did not receive a reply at all in a redis-cli session from these commands, blocking redis-cli trying to read the reply. This fixes issue #714.
-
- 19 Jan, 2013 2 commits
- 15 Jan, 2013 1 commit
-
-
antirez authored
-
- 10 Jan, 2013 1 commit
-
-
antirez authored
-
- 02 Dec, 2012 1 commit
-
-
antirez authored
-
- 30 Nov, 2012 2 commits
-
-
antirez authored
SDIFF used an algorithm that was O(N) where N is the total number of elements of all the sets involved in the operation. The algorithm worked like that: ALGORITHM 1: 1) For the first set, add all the members to an auxiliary set. 2) For all the other sets, remove all the members of the set from the auxiliary set. So it is an O(N) algorithm where N is the total number of elements in all the sets involved in the diff operation. Cristobal Viedma suggested to modify the algorithm to the following: ALGORITHM 2: 1) Iterate all the elements of the first set. 2) For every element, check if the element also exists in all the other remaining sets. 3) Add the element to the auxiliary set only if it does not exist in any of the other sets. The complexity of this algorithm on the worst case is O(N*M) where N is the size of the first set and M the total number of sets involved in the operation. However when there are elements in common, with this algorithm we stop the computation for a given element as long as we find a duplicated element into another set. I (antirez) added an additional step to algorithm 2 to make it faster, that is to sort the set to subtract from the biggest to the smallest, so that it is more likely to find a duplicate in a larger sets that are checked before the smaller ones. WHAT IS BETTER? None of course, for instance if the first set is much larger than the other sets the second algorithm does a lot more work compared to the first algorithm. Similarly if the first set is much smaller than the other sets, the original algorithm will less work. So this commit makes Redis able to guess the number of operations required by each algorithm, and select the best at runtime according to the input received. However, since the second algorithm has better constant times and can do less work if there are duplicated elements, an advantage is given to the second algorithm.
-
antirez authored
-
- 29 Nov, 2012 1 commit
-
-
antirez authored
-
- 22 Nov, 2012 4 commits
- 14 Nov, 2012 2 commits
- 12 Nov, 2012 1 commit
-
-
antirez authored
The previous behavior was to return -1 if: 1) Existing key but without an expire set. 2) Non existing key. Now the second case is handled in a different, and TTL will return -2 if the key does not exist at all. PTTL follows the same behavior as well.
-
- 07 Nov, 2012 2 commits
-
-
antirez authored
With COPY now MIGRATE does not remove the key from the source instance. With REPLACE it uses RESTORE REPLACE on the target host so that even if the key already eixsts in the target instance it will be overwritten. The options can be used together.
-
antirez authored
The REPLACE option deletes an existing key with the same name (if any) and materializes the new one. The default behavior without RESTORE is to return an error if a key already exists.
-
- 06 Nov, 2012 1 commit
-
-
antirez authored
So instead to reply with a generic error like: -ERR ... wrong kind of value ... now it replies with: -WRONGTYPE ... wrong kind of value ... This makes this particular error easy to check without resorting to (fragile) pattern matching of the error string (however the error string used to be consistent already). Client libraries should return a specific exeption type for this error. Most of the commit is about fixing unit tests.
-