Skip to main content

运行 wrk 和 wrk2 基准测试并存储其输出的工具。

项目描述

构建状态 皮皮 测试覆盖率

wrk工具箱

运行 wrk 和 wrk2 基准测试、存储其输出和生成报告的工具。

特征

快速示例

  1. 安装
pip install wrktools
  1. 验证 cli 是否有效(可选)
wrktoolbox --help
  1. 准备一个带有配置的 YAML 或 JSON 文件。具有单一类型基准的基本示例如下所示:
# the array of benchmarks contains the configuration of benchmarks to run
benchmarks:
  - url: https://this-is-an-example.it/api/alive
    threads: 10  # threads count
    concurrency: 100  # concurrent users
    duration: 30  # test duration in seconds

# the type of stores to use, to collect benchmark results
# it is possible to define custom stores, using plugins;
# for example to store results in a database, or send them to an API
stores:
  - json
  1. 使用设置文件运行一套基准测试
wrktoolbox run --settings basic.yaml

有关完整配置文件的示例,请参阅示例文件夹,定义用于身份验证和自定义存储的插件。

项目详情


下载文件

下载适用于您平台的文件。如果您不确定要选择哪个,请了解有关安装包的更多信息。

源分布

wrktools-0.1.9.tar.gz (19.8 kB 查看哈希

已上传 source

内置分布

wrktools-0.1.9-py3-none-any.whl (26.1 kB 查看哈希

已上传 py3