Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Make the MSET benchmark *really* work with 10 keys

  • Loading branch information...
commit d69a483556e7bcd8642723482bd1de1cc5a10ff4 1 parent f2f2424
@pietern pietern authored
Showing with 6 additions and 4 deletions.
  1. +6 −4 src/redis-benchmark.c
View
10 src/redis-benchmark.c
@@ -479,11 +479,13 @@ int main(int argc, char **argv) {
benchmark("PING",cmd,len);
free(cmd);
- const char *argv[11];
+ const char *argv[21];
argv[0] = "MSET";
- for (i = 1; i < 11; i++)
- argv[i] = data;
- len = redisFormatCommandArgv(&cmd,11,argv,NULL);
+ for (i = 1; i < 21; i += 2) {
+ argv[i] = "foo:rand:000000000000";
+ argv[i+1] = data;
+ }
+ len = redisFormatCommandArgv(&cmd,21,argv,NULL);
benchmark("MSET (10 keys)",cmd,len);
free(cmd);
Please sign in to comment.
Something went wrong with that request. Please try again.