redis-benchmarks-specification 0.1.325__py3-none-any.whl → 0.1.327__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Potentially problematic release.
This version of redis-benchmarks-specification might be problematic. Click here for more details.
- redis_benchmarks_specification/__common__/runner.py +1 -1
- redis_benchmarks_specification/__runner__/args.py +10 -0
- redis_benchmarks_specification/__runner__/runner.py +136 -22
- {redis_benchmarks_specification-0.1.325.dist-info → redis_benchmarks_specification-0.1.327.dist-info}/METADATA +1 -1
- {redis_benchmarks_specification-0.1.325.dist-info → redis_benchmarks_specification-0.1.327.dist-info}/RECORD +8 -8
- {redis_benchmarks_specification-0.1.325.dist-info → redis_benchmarks_specification-0.1.327.dist-info}/LICENSE +0 -0
- {redis_benchmarks_specification-0.1.325.dist-info → redis_benchmarks_specification-0.1.327.dist-info}/WHEEL +0 -0
- {redis_benchmarks_specification-0.1.325.dist-info → redis_benchmarks_specification-0.1.327.dist-info}/entry_points.txt +0 -0
|
@@ -101,7 +101,7 @@ def get_benchmark_specs(testsuites_folder, test="", test_regex=".*"):
|
|
|
101
101
|
for test_name in original_files:
|
|
102
102
|
match_obj = re.search(test_regexp_string, test_name)
|
|
103
103
|
if match_obj is None:
|
|
104
|
-
logging.
|
|
104
|
+
logging.debug(
|
|
105
105
|
"Skipping test file: {} given it does not match regex {}".format(
|
|
106
106
|
test_name, test_regexp_string
|
|
107
107
|
)
|
|
@@ -89,6 +89,16 @@ def create_client_runner_args(project_name):
|
|
|
89
89
|
default=".*",
|
|
90
90
|
help="Filter tests by command using regex. Only tests that include commands matching this regex will be processed (e.g., 'bitcount|bitpos').",
|
|
91
91
|
)
|
|
92
|
+
parser.add_argument(
|
|
93
|
+
"-u",
|
|
94
|
+
"--uri",
|
|
95
|
+
type=str,
|
|
96
|
+
default=None,
|
|
97
|
+
help="Server URI on format redis://user:password@host:port/dbnum. "
|
|
98
|
+
"User, password and dbnum are optional. For authentication "
|
|
99
|
+
"without a username, use username 'default'. For TLS, use "
|
|
100
|
+
"the scheme 'rediss'. If provided, overrides individual host/port/password arguments.",
|
|
101
|
+
)
|
|
92
102
|
parser.add_argument("--db_server_host", type=str, default="localhost")
|
|
93
103
|
parser.add_argument("--db_server_password", type=str, default=None)
|
|
94
104
|
parser.add_argument("--db_server_port", type=int, default=6379)
|
|
@@ -12,6 +12,7 @@ import traceback
|
|
|
12
12
|
from pathlib import Path
|
|
13
13
|
import re
|
|
14
14
|
import tqdm
|
|
15
|
+
from urllib.parse import urlparse
|
|
15
16
|
import docker
|
|
16
17
|
import redis
|
|
17
18
|
from docker.models.containers import Container
|
|
@@ -90,6 +91,73 @@ def signal_handler(signum, frame):
|
|
|
90
91
|
sys.exit(1)
|
|
91
92
|
|
|
92
93
|
|
|
94
|
+
def parse_redis_uri(uri):
|
|
95
|
+
"""
|
|
96
|
+
Parse Redis URI and extract connection parameters.
|
|
97
|
+
|
|
98
|
+
Args:
|
|
99
|
+
uri (str): Redis URI in format redis://user:password@host:port/dbnum
|
|
100
|
+
or rediss://user:password@host:port/dbnum for TLS
|
|
101
|
+
|
|
102
|
+
Returns:
|
|
103
|
+
dict: Dictionary containing parsed connection parameters
|
|
104
|
+
"""
|
|
105
|
+
if not uri:
|
|
106
|
+
return {}
|
|
107
|
+
|
|
108
|
+
try:
|
|
109
|
+
parsed = urlparse(uri)
|
|
110
|
+
|
|
111
|
+
# Extract connection parameters
|
|
112
|
+
params = {}
|
|
113
|
+
|
|
114
|
+
# Host (required)
|
|
115
|
+
if parsed.hostname:
|
|
116
|
+
params["host"] = parsed.hostname
|
|
117
|
+
|
|
118
|
+
# Port (optional, defaults to 6379)
|
|
119
|
+
if parsed.port:
|
|
120
|
+
params["port"] = parsed.port
|
|
121
|
+
|
|
122
|
+
# Username and password
|
|
123
|
+
if parsed.username:
|
|
124
|
+
params["username"] = parsed.username
|
|
125
|
+
if parsed.password:
|
|
126
|
+
params["password"] = parsed.password
|
|
127
|
+
|
|
128
|
+
# Database number
|
|
129
|
+
if parsed.path and len(parsed.path) > 1: # path starts with '/'
|
|
130
|
+
try:
|
|
131
|
+
params["db"] = int(parsed.path[1:]) # Remove leading '/'
|
|
132
|
+
except ValueError:
|
|
133
|
+
logging.warning(f"Invalid database number in URI: {parsed.path[1:]}")
|
|
134
|
+
|
|
135
|
+
# TLS detection
|
|
136
|
+
if parsed.scheme == "rediss":
|
|
137
|
+
params["tls_enabled"] = True
|
|
138
|
+
elif parsed.scheme == "redis":
|
|
139
|
+
params["tls_enabled"] = False
|
|
140
|
+
else:
|
|
141
|
+
logging.warning(
|
|
142
|
+
f"Unknown scheme in URI: {parsed.scheme}. Assuming non-TLS."
|
|
143
|
+
)
|
|
144
|
+
params["tls_enabled"] = False
|
|
145
|
+
|
|
146
|
+
logging.info(
|
|
147
|
+
f"Parsed Redis URI: host={params.get('host', 'N/A')}, "
|
|
148
|
+
f"port={params.get('port', 'N/A')}, "
|
|
149
|
+
f"username={params.get('username', 'N/A')}, "
|
|
150
|
+
f"db={params.get('db', 'N/A')}, "
|
|
151
|
+
f"tls={params.get('tls_enabled', False)}"
|
|
152
|
+
)
|
|
153
|
+
|
|
154
|
+
return params
|
|
155
|
+
|
|
156
|
+
except Exception as e:
|
|
157
|
+
logging.error(f"Failed to parse Redis URI '{uri}': {e}")
|
|
158
|
+
return {}
|
|
159
|
+
|
|
160
|
+
|
|
93
161
|
def run_local_command_with_timeout(command_str, timeout_seconds, description="command"):
|
|
94
162
|
"""
|
|
95
163
|
Run a local command with timeout support.
|
|
@@ -1443,35 +1511,81 @@ def process_self_contained_coordinator_stream(
|
|
|
1443
1511
|
build_variant_name = "NA"
|
|
1444
1512
|
git_branch = None
|
|
1445
1513
|
|
|
1446
|
-
|
|
1447
|
-
|
|
1514
|
+
# Parse URI if provided, otherwise use individual arguments
|
|
1515
|
+
if hasattr(args, "uri") and args.uri:
|
|
1516
|
+
uri_params = parse_redis_uri(args.uri)
|
|
1517
|
+
port = uri_params.get("port", args.db_server_port)
|
|
1518
|
+
host = uri_params.get("host", args.db_server_host)
|
|
1519
|
+
password = uri_params.get("password", args.db_server_password)
|
|
1520
|
+
# Override TLS setting from URI if specified
|
|
1521
|
+
if "tls_enabled" in uri_params:
|
|
1522
|
+
tls_enabled = uri_params["tls_enabled"]
|
|
1523
|
+
if tls_enabled:
|
|
1524
|
+
test_name = test_name + "-tls"
|
|
1525
|
+
logging.info(
|
|
1526
|
+
"TLS enabled via URI. Appending -tls to testname."
|
|
1527
|
+
)
|
|
1528
|
+
# Note: username and db are handled by redis-py automatically when using URI
|
|
1529
|
+
logging.info(
|
|
1530
|
+
f"Using connection parameters from URI: host={host}, port={port}, tls={tls_enabled}"
|
|
1531
|
+
)
|
|
1532
|
+
else:
|
|
1533
|
+
port = args.db_server_port
|
|
1534
|
+
host = args.db_server_host
|
|
1535
|
+
password = args.db_server_password
|
|
1536
|
+
logging.info(
|
|
1537
|
+
f"Using individual connection arguments: host={host}, port={port}"
|
|
1538
|
+
)
|
|
1539
|
+
|
|
1448
1540
|
unix_socket = args.unix_socket
|
|
1449
|
-
password = args.db_server_password
|
|
1450
1541
|
oss_cluster_api_enabled = args.cluster_mode
|
|
1451
1542
|
ssl_cert_reqs = "required"
|
|
1452
1543
|
if tls_skip_verify:
|
|
1453
1544
|
ssl_cert_reqs = None
|
|
1454
1545
|
|
|
1455
|
-
#
|
|
1456
|
-
|
|
1457
|
-
|
|
1458
|
-
|
|
1459
|
-
|
|
1460
|
-
|
|
1461
|
-
|
|
1462
|
-
"ssl_check_hostname": False,
|
|
1463
|
-
}
|
|
1464
|
-
|
|
1465
|
-
# Only add SSL certificate parameters if they are provided
|
|
1466
|
-
if tls_enabled:
|
|
1467
|
-
if tls_key is not None and tls_key != "":
|
|
1468
|
-
redis_params["ssl_keyfile"] = tls_key
|
|
1469
|
-
if tls_cert is not None and tls_cert != "":
|
|
1470
|
-
redis_params["ssl_certfile"] = tls_cert
|
|
1471
|
-
if tls_cacert is not None and tls_cacert != "":
|
|
1472
|
-
redis_params["ssl_ca_certs"] = tls_cacert
|
|
1546
|
+
# Create Redis connection - use URI if provided, otherwise use individual parameters
|
|
1547
|
+
if hasattr(args, "uri") and args.uri:
|
|
1548
|
+
# Use URI connection (redis-py handles URI parsing automatically)
|
|
1549
|
+
redis_params = {
|
|
1550
|
+
"ssl_cert_reqs": ssl_cert_reqs,
|
|
1551
|
+
"ssl_check_hostname": False,
|
|
1552
|
+
}
|
|
1473
1553
|
|
|
1474
|
-
|
|
1554
|
+
# Add SSL certificate parameters if TLS is enabled and certificates are provided
|
|
1555
|
+
if tls_enabled:
|
|
1556
|
+
if tls_key is not None and tls_key != "":
|
|
1557
|
+
redis_params["ssl_keyfile"] = tls_key
|
|
1558
|
+
if tls_cert is not None and tls_cert != "":
|
|
1559
|
+
redis_params["ssl_certfile"] = tls_cert
|
|
1560
|
+
if tls_cacert is not None and tls_cacert != "":
|
|
1561
|
+
redis_params["ssl_ca_certs"] = tls_cacert
|
|
1562
|
+
|
|
1563
|
+
r = redis.StrictRedis.from_url(args.uri, **redis_params)
|
|
1564
|
+
logging.info(f"Connected to Redis using URI: {args.uri}")
|
|
1565
|
+
else:
|
|
1566
|
+
# Use individual connection parameters
|
|
1567
|
+
redis_params = {
|
|
1568
|
+
"host": host,
|
|
1569
|
+
"port": port,
|
|
1570
|
+
"password": password,
|
|
1571
|
+
"ssl": tls_enabled,
|
|
1572
|
+
"ssl_cert_reqs": ssl_cert_reqs,
|
|
1573
|
+
"ssl_check_hostname": False,
|
|
1574
|
+
}
|
|
1575
|
+
|
|
1576
|
+
# Only add SSL certificate parameters if they are provided
|
|
1577
|
+
if tls_enabled:
|
|
1578
|
+
if tls_key is not None and tls_key != "":
|
|
1579
|
+
redis_params["ssl_keyfile"] = tls_key
|
|
1580
|
+
if tls_cert is not None and tls_cert != "":
|
|
1581
|
+
redis_params["ssl_certfile"] = tls_cert
|
|
1582
|
+
if tls_cacert is not None and tls_cacert != "":
|
|
1583
|
+
redis_params["ssl_ca_certs"] = tls_cacert
|
|
1584
|
+
|
|
1585
|
+
r = redis.StrictRedis(**redis_params)
|
|
1586
|
+
logging.info(
|
|
1587
|
+
f"Connected to Redis using individual parameters: {host}:{port}"
|
|
1588
|
+
)
|
|
1475
1589
|
setup_name = "oss-standalone"
|
|
1476
1590
|
r.ping()
|
|
1477
1591
|
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
Metadata-Version: 2.1
|
|
2
2
|
Name: redis-benchmarks-specification
|
|
3
|
-
Version: 0.1.
|
|
3
|
+
Version: 0.1.327
|
|
4
4
|
Summary: The Redis benchmarks specification describes the cross-language/tools requirements and expectations to foster performance and observability standards around redis related technologies. Members from both industry and academia, including organizations and individuals are encouraged to contribute.
|
|
5
5
|
Author: filipecosta90
|
|
6
6
|
Author-email: filipecosta.90@gmail.com
|
|
@@ -15,7 +15,7 @@ redis_benchmarks_specification/__common__/builder_schema.py,sha256=kfDpRIk7NkJrb
|
|
|
15
15
|
redis_benchmarks_specification/__common__/env.py,sha256=kvJ8Ll-fvI_Tc0vynrzUEr22TqnJizzvJ4Lu9RjNr_M,3119
|
|
16
16
|
redis_benchmarks_specification/__common__/github.py,sha256=9TZtnISsSgXTSAN_VQejo5YRPDPhlU0gjxgKGPw_sP8,10699
|
|
17
17
|
redis_benchmarks_specification/__common__/package.py,sha256=4uVt1BAZ999LV2rZkq--Tk6otAVIf9YR3g3KGeUpiW4,834
|
|
18
|
-
redis_benchmarks_specification/__common__/runner.py,sha256=
|
|
18
|
+
redis_benchmarks_specification/__common__/runner.py,sha256=qX2LOjlM84CEwPnSHFSCQXFFHYQNbQHelNQVZlNjlmQ,16789
|
|
19
19
|
redis_benchmarks_specification/__common__/spec.py,sha256=D_SN48wg6NMthW_-OS1H5bydSDiuZpfd4WPPj7Vfwmc,5760
|
|
20
20
|
redis_benchmarks_specification/__common__/timeseries.py,sha256=uvS3T2zdrSmW_B2S0MYTekJfHUllqU3RlD0LrF957RQ,52904
|
|
21
21
|
redis_benchmarks_specification/__compare__/__init__.py,sha256=DtBXRp0Q01XgCFmY-1OIePMyyYihVNAjZ1Y8zwqSDN0,101
|
|
@@ -23,9 +23,9 @@ redis_benchmarks_specification/__compare__/args.py,sha256=CNtA7pI9CJDTBJPGL2pNVf
|
|
|
23
23
|
redis_benchmarks_specification/__compare__/compare.py,sha256=_AbuV3FZxtUZIdq4qq24LNzPNIdtQQaqrk8bUjn9blk,84327
|
|
24
24
|
redis_benchmarks_specification/__init__.py,sha256=YQIEx2sLPPA0JR9OuCuMNMNtm-f_gqDKgzvNJnkGNKY,491
|
|
25
25
|
redis_benchmarks_specification/__runner__/__init__.py,sha256=l-G1z-t6twUgi8QLueqoTQLvJmv3hJoEYskGm6H7L6M,83
|
|
26
|
-
redis_benchmarks_specification/__runner__/args.py,sha256=
|
|
26
|
+
redis_benchmarks_specification/__runner__/args.py,sha256=K3VGmBC0-9lSv9H6VDp0N-6FGMWvc_4H0pG_TOXN5u8,11312
|
|
27
27
|
redis_benchmarks_specification/__runner__/remote_profiling.py,sha256=R7obNQju8mmY9oKkcndjI4aAuxi84OCLhDSqqaYu1SU,18610
|
|
28
|
-
redis_benchmarks_specification/__runner__/runner.py,sha256=
|
|
28
|
+
redis_benchmarks_specification/__runner__/runner.py,sha256=E4D9ubVnjFcihuRHMeICfgf0MgzWCUbo-boacypLc1c,150973
|
|
29
29
|
redis_benchmarks_specification/__self_contained_coordinator__/__init__.py,sha256=l-G1z-t6twUgi8QLueqoTQLvJmv3hJoEYskGm6H7L6M,83
|
|
30
30
|
redis_benchmarks_specification/__self_contained_coordinator__/args.py,sha256=uxBjdQ78klvsVi6lOfGYQVaWIxc8OI-DwYKY16SgvCY,5952
|
|
31
31
|
redis_benchmarks_specification/__self_contained_coordinator__/artifacts.py,sha256=OVHqJzDgeSSRfUSiKp1ZTAVv14PvSbk-5yJsAAoUfpw,936
|
|
@@ -281,8 +281,8 @@ redis_benchmarks_specification/test-suites/memtier_benchmark-playbook-session-st
|
|
|
281
281
|
redis_benchmarks_specification/test-suites/memtier_benchmark-playbook-session-storage-1k-sessions.yml,sha256=2egtIxPxCze2jlbAfgsk4v9JSQHNMoPLbDWFEW8olDg,7006
|
|
282
282
|
redis_benchmarks_specification/test-suites/template.txt,sha256=ezqGiRPOvuSDO0iG7GEf-AGXNfHbgXI89_G0RUEzL88,481
|
|
283
283
|
redis_benchmarks_specification/vector-search-test-suites/vector_db_benchmark_test.yml,sha256=PD7ow-k4Ll2BkhEC3aIqiaCZt8Hc4aJIp96Lw3J3mcI,791
|
|
284
|
-
redis_benchmarks_specification-0.1.
|
|
285
|
-
redis_benchmarks_specification-0.1.
|
|
286
|
-
redis_benchmarks_specification-0.1.
|
|
287
|
-
redis_benchmarks_specification-0.1.
|
|
288
|
-
redis_benchmarks_specification-0.1.
|
|
284
|
+
redis_benchmarks_specification-0.1.327.dist-info/LICENSE,sha256=xx0jnfkXJvxRnG63LTGOxlggYnIysveWIZ6H3PNdCrQ,11357
|
|
285
|
+
redis_benchmarks_specification-0.1.327.dist-info/METADATA,sha256=62EJm_MZYnoZyT3vbaFQLI7oBNnus1WYHm0Wv5RLonE,22768
|
|
286
|
+
redis_benchmarks_specification-0.1.327.dist-info/WHEEL,sha256=sP946D7jFCHeNz5Iq4fL4Lu-PrWrFsgfLXbbkciIZwg,88
|
|
287
|
+
redis_benchmarks_specification-0.1.327.dist-info/entry_points.txt,sha256=x5WBXCZsnDRTZxV7SBGmC65L2k-ygdDOxV8vuKN00Nk,715
|
|
288
|
+
redis_benchmarks_specification-0.1.327.dist-info/RECORD,,
|
|
File without changes
|
|
File without changes
|