Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
[tool.poetry]
name = "redisbench-admin"
version = "0.11.35"
version = "0.11.37"
description = "Redis benchmark run helper. A wrapper around Redis and Redis Modules benchmark tools ( ftsb_redisearch, memtier_benchmark, redis-benchmark, aibench, etc... )."
authors = ["filipecosta90 <[email protected]>","Redis Performance Group <[email protected]>"]
readme = "README.md"
Expand Down
14 changes: 13 additions & 1 deletion redisbench_admin/export/args.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,13 +4,18 @@
# All rights reserved.
#
import datetime

import os
from redisbench_admin.utils.remote import (
PERFORMANCE_RTS_HOST,
PERFORMANCE_RTS_PORT,
PERFORMANCE_RTS_AUTH,
)

ARCH_X86 = "x86_64"
ARCH_ARM = "aarch64"
VALID_ARCHS = [ARCH_X86, ARCH_ARM]
ARCH = os.getenv("ARCH", ARCH_X86)


def create_export_arguments(parser):
parser.add_argument(
Expand All @@ -19,6 +24,13 @@
required=True,
help="benchmark results file to read results from.",
)
parser.add_argument(

Check warning on line 27 in redisbench_admin/export/args.py

View check run for this annotation

Codecov / codecov/patch

redisbench_admin/export/args.py#L27

Added line #L27 was not covered by tests
"--architecture",
type=str,
required=False,
default=ARCH,
help=f"Architecture to run the benchmark on. One of {VALID_ARCHS}.",
)
parser.add_argument(
"--exporter-spec-file",
type=str,
Expand Down
14 changes: 14 additions & 0 deletions redisbench_admin/export/export.py
Original file line number Diff line number Diff line change
Expand Up @@ -77,8 +77,19 @@
_,
_,
) = get_defaults(exporter_spec_file)
arch = args.architecture
logging.info("Using the following architecture on the timeseries: {}".format(arch))

Check warning on line 81 in redisbench_admin/export/export.py

View check run for this annotation

Codecov / codecov/patch

redisbench_admin/export/export.py#L80-L81

Added lines #L80 - L81 were not covered by tests

extra_tags_dict = split_tags_string(args.extra_tags)
if "results_format" not in extra_tags_dict:
extra_tags_dict["results_format"] = results_format
logging.info(f"Adding results_format={results_format} to extra tags")
if "arch" not in extra_tags_dict:
extra_tags_dict["arch"] = arch
logging.info(f"Adding arch={arch} to extra tags")
if "architecture" not in extra_tags_dict:
extra_tags_dict["architecture"] = arch
logging.info(f"Adding architecture={arch} to extra tags")

Check warning on line 92 in redisbench_admin/export/export.py

View check run for this annotation

Codecov / codecov/patch

redisbench_admin/export/export.py#L84-L92

Added lines #L84 - L92 were not covered by tests
logging.info("Using the following extra tags: {}".format(extra_tags_dict))

results_dict = {}
Expand Down Expand Up @@ -161,6 +172,7 @@
github_org,
github_repo,
triggering_env,
arch,
)
logging.info("Parsed a total of {} metrics".format(len(timeseries_dict.keys())))
logging.info(
Expand Down Expand Up @@ -221,6 +233,7 @@
tf_github_org,
tf_github_repo,
triggering_env,
arch,
):
results_dict = {}
for test_name, d in benchmark_file.items():
Expand All @@ -245,6 +258,7 @@
tf_github_repo,
triggering_env,
False,
arch,
)
results_dict[ts_name] = {
"labels": timeserie_tags.copy(),
Expand Down
2 changes: 2 additions & 0 deletions tests/test_export.py
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,8 @@ def test_export_command_logic_google_benchmark():
"{}".format(rts_pass),
"--github_branch",
"branch-feature-1",
"--architecture",
"x86_64",
]
)
try:
Expand Down