Crates.io | inquisitor |
lib.rs | inquisitor |
version | 0.8.4 |
source | src |
created_at | 2022-10-26 18:24:09.886502 |
updated_at | 2023-08-19 12:15:19.639543 |
description | Simple and fast load testing tool |
homepage | https://github.com/yds12/inquisitor |
repository | https://github.com/yds12/inquisitor |
max_upload_size | |
id | 698085 |
size | 49,223 |
Simple and fast HTTP load testing tool written in Rust. All the actual functionality is provided by inquisitor-core, while this crate contains the command-line executable.
This project is currently a work in progress.
Clone the repo and build:
$ git clone https://github.com/yds12/inquisitor
$ cd inquisitor
$ cargo build --release
Install via cargo
with:
$ cargo install inquisitor
As an example, you can run with:
$ inquisitor -n 1000 -c 10 https://localhost:8080/test
This will hit the URL specified, (at least and approximately) -n
number of
times, using a pool of -c
HTTP
connections (in parallel, one tokio
task per connection). These parameters
need to be adjusted according to your environment.
Another way to run the tests is limiting by duration instead of total number of
requests, via the -d
parameter (below we limit it to 15 seconds):
$ inquisitor -d 15s https://localhost:8080/test
Other useful option is -k
for insecure connections, ignoring TLS certificates.
You can also do POST requests (with -b
for the request body):
$ inquisitor -d 1m --method post -b "hello" https://localhost:8080/test
To set the request headers, you can use the -H
option (once per header):
$ inquisitor -d 1m --method post -b "hello" \
-H "Content-Type:text/plain" -H "User-Agent:Inquisitor/8.0" \
https://localhost:8080/test
For more useful options, type:
$ inquisitor --help
Here's an example output:
$ inquisitor -d 20s https://localhost:8080/test
total time: 20.0 s
errors: 0/651526
throughput: 32574 req./s
response times:
mean 362 us
st.dev 362 us
min 68 us
max 18.8 ms
latencies:
50% 316 us
75% 522 us
90% 546 us
95% 571 us
99% 843 us
99.9% 5.54 ms
There are some other tools in this category in Rust, such as Goose and Drill. Inquisitor is inspired more by tools such as wrk and siege than Goose, Drill or k6, which means that we want our tool to be:
From the tools that I have tried, by far the one capable of generating the
highest number of RPS is wrk
, which in my hardware will do something around
30-70k RPS. These numbers are significantly larger than the RPS of some of the
tools I mentioned, and orders of magnitude higher than some others. This is the
main motivation of Inquisitor: reach the level of RPS of wrk
, while being
written in Rust and if possible slowly add features that the comunity deems to
be useful.
We will follow semantic versioning. Before 1.0, we will bump the MINOR number when there are breaking changes in the UI/CLI (e.g. change or removal of CLI options, change in the output format). For new features that don't alter the program's behavior while using the previously existing CLI options (e.g. addition of a new CLI option that don't change the program's behavior when not used), and minor patches, we will just bump the PATCH number.