diff options
author | antirez <antirez@gmail.com> | 2018-06-15 13:14:57 +0200 |
---|---|---|
committer | antirez <antirez@gmail.com> | 2019-06-18 12:31:10 +0200 |
commit | e9bb30fd859ed4e9e3e6434207dedbc251086858 (patch) | |
tree | 0ac8972fefe6911dee8c7376e14c611fcc105e1c /src/hyperloglog.c | |
parent | fd0ee469ab165d0e005e9fe1fca1c4f5c604cd56 (diff) | |
download | redis-new-keyspace.tar.gz |
Experimental: new keyspace and expire algorithm.new-keyspace
This is an alpha quality implementation of a new keyspace representation
and a new expire algorithm for Redis.
This work is described here:
https://gist.github.com/antirez/b2eb293819666ee104c7fcad71986eb7
Diffstat (limited to 'src/hyperloglog.c')
-rw-r--r-- | src/hyperloglog.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/hyperloglog.c b/src/hyperloglog.c index e01ea6042..161ae9457 100644 --- a/src/hyperloglog.c +++ b/src/hyperloglog.c @@ -1179,7 +1179,7 @@ invalid: /* PFADD var ele ele ele ... ele => :0 or :1 */ void pfaddCommand(client *c) { - robj *o = lookupKeyWrite(c->db,c->argv[1]); + robj *o = lookupKeyWrite(c->db,c->argv[1],NULL); struct hllhdr *hdr; int updated = 0, j; @@ -1238,7 +1238,7 @@ void pfcountCommand(client *c) { registers = max + HLL_HDR_SIZE; for (j = 1; j < c->argc; j++) { /* Check type and size. */ - robj *o = lookupKeyRead(c->db,c->argv[j]); + robj *o = lookupKeyRead(c->db,c->argv[j],NULL); if (o == NULL) continue; /* Assume empty HLL for non existing var.*/ if (isHLLObjectOrReply(c,o) != C_OK) return; @@ -1259,7 +1259,7 @@ void pfcountCommand(client *c) { * * The user specified a single key. Either return the cached value * or compute one and update the cache. */ - o = lookupKeyWrite(c->db,c->argv[1]); + o = lookupKeyWrite(c->db,c->argv[1],NULL); if (o == NULL) { /* No key? Cardinality is zero since no element was added, otherwise * we would have a key as HLLADD creates it as a side effect. */ @@ -1320,7 +1320,7 @@ void pfmergeCommand(client *c) { memset(max,0,sizeof(max)); for (j = 1; j < c->argc; j++) { /* Check type and size. */ - robj *o = lookupKeyRead(c->db,c->argv[j]); + robj *o = lookupKeyRead(c->db,c->argv[j],NULL); if (o == NULL) continue; /* Assume empty HLL for non existing var. */ if (isHLLObjectOrReply(c,o) != C_OK) return; @@ -1338,7 +1338,7 @@ void pfmergeCommand(client *c) { } /* Create / unshare the destination key's value if needed. */ - robj *o = lookupKeyWrite(c->db,c->argv[1]); + robj *o = lookupKeyWrite(c->db,c->argv[1],NULL); if (o == NULL) { /* Create the key with a string value of the exact length to * hold our HLL data structure. sdsnewlen() when NULL is passed @@ -1497,7 +1497,7 @@ void pfdebugCommand(client *c) { robj *o; int j; - o = lookupKeyWrite(c->db,c->argv[2]); + o = lookupKeyWrite(c->db,c->argv[2],NULL); if (o == NULL) { addReplyError(c,"The specified key does not exist"); return; |