Skip to content

Commit 4576e8a

Browse files
Enabled --cluster-mode in client runner (#199)
1 parent 1a5dbc2 commit 4576e8a

File tree

2 files changed

+12
-3
lines changed

2 files changed

+12
-3
lines changed

redis_benchmarks_specification/__runner__/args.py

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -190,4 +190,10 @@ def create_client_runner_args(project_name):
190190
type=int,
191191
help="override memtier number of runs for each benchmark. By default will run once each test",
192192
)
193+
parser.add_argument(
194+
"--cluster-mode",
195+
default=False,
196+
action="store_true",
197+
help="Run client in cluster mode.",
198+
)
193199
return parser

redis_benchmarks_specification/__runner__/runner.py

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -410,7 +410,7 @@ def process_self_contained_coordinator_stream(
410410
port = args.db_server_port
411411
host = args.db_server_host
412412
password = args.db_server_password
413-
413+
oss_cluster_api_enabled = args.cluster_mode
414414
ssl_cert_reqs = "required"
415415
if tls_skip_verify:
416416
ssl_cert_reqs = None
@@ -553,6 +553,7 @@ def process_self_contained_coordinator_stream(
553553
test_tls_cacert,
554554
resp_version,
555555
password,
556+
oss_cluster_api_enabled,
556557
)
557558
execute_init_commands(
558559
benchmark_config, r, dbconfig_keyname="dbconfig"
@@ -596,6 +597,7 @@ def process_self_contained_coordinator_stream(
596597
local_benchmark_output_filename
597598
)
598599
)
600+
599601
if "memtier_benchmark" not in benchmark_tool:
600602
# prepare the benchmark command
601603
(
@@ -622,7 +624,7 @@ def process_self_contained_coordinator_stream(
622624
host,
623625
password,
624626
local_benchmark_output_filename,
625-
False,
627+
oss_cluster_api_enabled,
626628
tls_enabled,
627629
tls_skip_verify,
628630
test_tls_cert,
@@ -970,6 +972,7 @@ def data_prepopulation_step(
970972
tls_cacert=None,
971973
resp_version=None,
972974
password=None,
975+
oss_cluster_api_enabled=False,
973976
):
974977
# setup the benchmark
975978
(
@@ -999,7 +1002,7 @@ def data_prepopulation_step(
9991002
host,
10001003
password,
10011004
local_benchmark_output_filename,
1002-
False,
1005+
oss_cluster_api_enabled,
10031006
tls_enabled,
10041007
tls_skip_verify,
10051008
tls_cert,

0 commit comments

Comments
 (0)