Reworked wrk - Managed HTTP benchmarking tool
Request Feature | Report Bug
Table of Contents
Rewrk, a wrk HTTP Benchmarking Wrapper Script, is designed to abstract the complexity of managing wrk processes. It provides functionality for both single benchmarking test and sequential benchmarking as batch operations, provided via configuration file (.json), making load testing and benchmarking of HTTP servers straightforward.
- OS(s)
MacOS[BSDbased]- any
*nix[GNU+LinuxandUnix]
To set up a local instance of the application, follow the steps below.
brew tap proffapt/brewtap
brew install rewrkThe following dependencies are required to be installed for the project to function properly:
-
wrkFollow the installation instructions for your platform for wrk.
-
jqsudo apt install jq # Ubuntu/Debian sudo yum install jq # CentOS/Fedora brew install jq # macOS (HomeBrew)
Now that the environment has been set up and configured to properly compile and run the project, the next step is to install and configure the project locally on your system.
- Clone the repository
git clone https://github.com/proffapt/rewrk.git
- Make the script executable
cd ./rewrk chmod +x ./rewrk - Execute the script
./rewrk
Usage: ./rewrk COMMAND [OPTIONS]
A wrapper script to manage wrk HTTP benchmarking tool
Commands:
status Show the status of wrk process
start ARGS Start a single wrk instance with specified parameters
Arguments:
threads Number of threads to use
connections Number of connections to keep open
duration Duration of the test (e.g., 30s, 1m, 1h)
url Target URL
[timeout] Optional: Request timeout (default: 30s)
stop Stop the running wrk process
bstart ARGS Start batch wrk processes using a configuration file
Arguments:
load_pattern_file JSON file containing load patterns
url Target URL
[timeout] Optional: Request timeout (default: 30s)
bstop Stop all wrk processes in the batch
Example JSON load pattern file format:
{
[
{
"threads": 1,
"connections": 2,
"duration": "1h"
},
{
"threads": 1,
"connections": 1,
"duration": "1h"
}
]
}
Examples:
./rewrk status
./rewrk start 1 2 10m http://example.com/load/1
./rewrk bstart load.example.json http://example.com/load/1
./rewrk stop
./rewrk bstop