diff options
author | vanguard_space <mailmahee@gmail.com> | 2023-02-02 09:18:22 -0800 |
---|---|---|
committer | GitHub <noreply@github.com> | 2023-02-02 09:18:22 -0800 |
commit | 3b260149e0996b8ee12510b0b9508bca56743269 (patch) | |
tree | 9dd927612576cd3de7351b7563df70c5c52706eb /src | |
parent | fd3975684a8e9e45c77d3b14cb1883572956efe7 (diff) | |
download | redis-3b260149e0996b8ee12510b0b9508bca56743269.tar.gz |
adding the ability to add streams to the pre-defined redis-benchmark tests (#11762)
Added standard way to support xadd as one of the commands that can be run via redis-benchmarking tool
Diffstat (limited to 'src')
-rw-r--r-- | src/redis-benchmark.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/src/redis-benchmark.c b/src/redis-benchmark.c index c5dd187b8..0d10e8d3f 100644 --- a/src/redis-benchmark.c +++ b/src/redis-benchmark.c @@ -2030,6 +2030,12 @@ int main(int argc, char **argv) { sdsfree(key_placeholder); } + if (test_is_selected("xadd")) { + len = redisFormatCommand(&cmd,"XADD mystream%s * myfield %s", tag, data); + benchmark("XADD",cmd,len); + free(cmd); + } + if (!config.csv) printf("\n"); } while(config.loop); |