Skip to content

Commit fdd22d8

Browse files
YaacovHazanushachar
authored andcommitted
add support for cluster mode (#42)
new 'cluster_client' add to support cluster mode. the new client use CLUSTER_SLOTS command to retrive the key-->node mapping, create separate connection fot each node, and send the commands to the appropriate connection according to hash calculation.
1 parent dc90a8d commit fdd22d8

15 files changed

+1659
-568
lines changed

Makefile.am

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,8 @@ memtier_benchmark_CPPFLAGS = $(LIBEVENT_CFLAGS)
2525
memtier_benchmark_SOURCES = \
2626
memtier_benchmark.cpp memtier_benchmark.h \
2727
client.cpp client.h \
28+
cluster_client.cpp cluster_client.h \
29+
shard_connection.cpp shard_connection.h connections_manager.h \
2830
JSON_handler.cpp JSON_handler.h \
2931
protocol.cpp protocol.h \
3032
obj_gen.cpp obj_gen.h \

README.md

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -9,6 +9,7 @@ memtier_benchmark is a command line utility developed by Redis Labs (formerly Ga
99
* Read:Write ratio
1010
* Random and sequential key name pattern policies
1111
* Random or ranged key expiration
12+
* Redis cluster
1213
* ...and much more
1314

1415
Read more at:
@@ -73,6 +74,13 @@ On recent Ubuntu versions, simply install all prerequisites as follows:
7374
```
7475

7576

77+
### Cluster mode
78+
79+
In case where there is some asymmetry between the redis nodes, and user set
80+
the number of total requests with sequential key pattern options, it might be
81+
gaps in the generated keys.
82+
83+
7684
### Building and installing
7785

7886
After downloading the source tree, use standard autoconf/automake commands::

0 commit comments

Comments
 (0)