Skip to content

Commit 74e8fdb

Browse files
committed
List packages with benchmarks
For someone to run benchmarks or ingest sample data it is currently not easy to find the packages that have templates for benchmarks available. This is a quick POC on how the list of integrations with benchmarks can be generated. Some ideas on how this could be used: * Add the list to the docs page around streaming data. Downside is that it needs to be manually (or automatically) updated from time to time * Add some command to elastic-package to list the packages with templates * Other ideas? The current output of the script looks as following: ``` python list_benchmark_packages.py Package: nginx * stubstatus-benchmark * error-benchmark Package: mysql * performance-benchmark Package: aws * sqs-benchmark * ec2metrics-benchmark * billing-benchmark * ec2logs-benchmark Package: kubernetes * container-benchmark * pod-benchmark
1 parent 3d0c32f commit 74e8fdb

File tree

1 file changed

+24
-0
lines changed

1 file changed

+24
-0
lines changed

scripts/list_benchmark_packages.py

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
#!/usr/bin/env python
2+
3+
import os
4+
5+
integrations_repo_path = "../../integrations"
6+
packages_path = os.path.join(integrations_repo_path, "packages")
7+
8+
# Iterate through all packages
9+
for package_path in os.listdir(packages_path):
10+
11+
rally_path = os.path.join(packages_path, package_path, "_dev", "benchmark", "rally")
12+
13+
# Find packages with a rally directory
14+
if os.path.isdir(rally_path):
15+
print("Package: " + package_path)
16+
17+
benchmarks = os.listdir(rally_path)
18+
# List benchmarks
19+
for b in benchmarks:
20+
if not os.path.isdir(os.path.join(rally_path, b)):
21+
continue
22+
print("* " + b + "")
23+
24+
print("")

0 commit comments

Comments
 (0)