PUT /hive/poke
starts the load test.
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
The amount of threads per wasp Default:10 Optional
The amount of concurrency per wasp Default:50 Optional
How long to run the test in seconds. Default:30 Optional
Socket timeout in seconds Default:2 Optional
The target url to hit
The method to use to hit the target url Default:GET Optional
Headers to be sent to the target url Default:{} Optional
Body to be sent to the target url Optional
Wrk lua script code to execute Optional
Body
{
"t":10,
"c":50,
"d":5,
"target":"http://127.0.0.1:1234/",
"method":"GET",
"headers": {
"content-type": "application/json",
"some-random-header": "hi"
},
"body" : "{\n \"foo\": \"bar\",\n \"lar\": \"moo\"\n}",
"timeout": 2,
"script": "-- Lua script code here"
}
Sample cURL
$ curl -X PUT \
/hive/poke \
-H "Content-Type: application/json" \
-H "cache-control: no-cache" \
-d '{
"t":10,
"c":50,
"d":5,
"target":"http://127.0.0.1:1234/"
}'
DELETE /hive/torch
Deletes all wasps that have checked in.
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Sample cURL
$ curl -X DELETE \
/hive/torch \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
GET /hive/ceasefire
Stops all the wasps from shooting.
Sample cURL
$ curl -X GET \
/hive/ceasefire \
-H "cache-control: no-cache"
GET /hive/spawn/local/:amount
Spawns local wasps by the specified amount.
Path Variables
| key | value | description |
|---|---|---|
| amount | 2 | Number of wasps to spawn |
Sample cURL
$ curl -X GET \
/hive/spawn/local/2 \
-H "cache-control: no-cache"
GET /hive/status
Gives the current operational status of the hive.
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Sample cURL
$ curl -X GET \
/hive/status \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
GET /hive/status/report
Gives full report of the load test.
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Sample cURL
$ curl -X GET \
/hive/status/report \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
GET /hive/status/report/:field
Getting just what you want from the report.
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Path Variables
| key | value | description |
|---|---|---|
| field | totalRPS | The field you want to retrieve |
Sample cURL
$ curl -X GET \
/hive/status/report/totalRPS \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
GET /hive/status/done
Returns 200 when the loadtest is done.
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Sample cURL
$ curl -X GET \
/hive/status/done \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
GET /wasp/list
Lists all current wasps that have checked in.
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Sample cURL
$ curl -X GET \
/wasp/list \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
GET /wasp/boop/snoots
Force a health check on all the wasps to see if they’re alive.
Sample cURL
$ curl -X GET \
/wasp/boop/snoots \
-H "cache-control: no-cache"
PUT /wasp/reportin/:id
Wasps hits this endpoint when the load test is done with its results
This is used by the wasp and should not be used directly
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Path Variables
| key | value | description |
|---|---|---|
| id | waspsid | Wasp’s ID |
Sample cURL
$ curl -X PUT \
/wasp/reportin/wasp1 \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
PUT /wasp/reportin/:id/failed
Wasps hits this endpoint when the load test has failed
This is used by the wasp and should not be used directly
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Path Variables
| key | value | description |
|---|---|---|
| id | waspsid | Wasp’s ID |
Sample cURL
$ curl -X PUT \
/wasp/reportin/wasp1/failed \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
GET /wasp/checkin/:port
Wasps hits this endpoint when it first starts up to let hive know its IP and port number.
This is used by the wasp and should not be used directly
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Path Variables
| key | value | description |
|---|---|---|
| port | 1234 | Wasp’s port number |
Sample cURL
$ curl -X GET \
/wasp/checkin/4268 \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
GET /wasp/heartbeat/:port
Wasps hit this endpoint every 5 seconds to let Hive know they are not dead.
This is used by the wasp and should not be used directly
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
Path Variables
| key | value | description |
|---|---|---|
| port | 1234 | Wasp’s port number |
Sample cURL
$ curl -X GET \
/wasp/heartbeat/4268 \
-H "Content-Type: application/json" \
-H "cache-control: no-cache"
PUT /fire
Have the wasp start the loadtest.
Headers
| key | type | value | description |
|---|---|---|---|
| Content-Type | text |
application/json |
The amount of threads Default:10 Optional
The amount of concurrency Default:50 Optional
How long to run the test in seconds. Default:30 Optional
Socket timeout in seconds Default:2 Optional
The target url to hit
The method to use to hit the target url Default:GET Optional
Headers to be sent to the target url Default:{} Optional
Body to be sent to the target url Optional
Wrk lua script code to execute Optional
Body
{
"t":12,
"c":400,
"d":10,
"target":"https://127.0.0.1:3001/",
"method": "GET",
"headers": {
"content-type": "application/json",
"some-random-header": "hi"
},
"body" : "{\n \"foo\": \"bar\",\n \"lar\": \"moo\"\n}",
"timeout": 2,
"script": "-- Lua script code here"
}
Sample cURL
$ curl -X PUT \
/fire \
-H "Content-Type: application/json" \
-H "cache-control: no-cache" \
-d '{
"t":10,
"c":50,
"d":5,
"target":"http://127.0.0.1:1234/"
}'
DELETE /die
Kill the wasp like the fearful god you are.
Sample cURL
$ curl -X DELETE \
/die \
-H "cache-control: no-cache"
GET /boop
Boop the snoot of the wasp to see if it’s still alive.
Sample cURL
$ curl -X GET \
/boop \
-H "cache-control: no-cache"
GET /ceasefire
Tells the wasp to stop shooting.
Sample cURL
$ curl -X GET \
/ceasefire \
-H "cache-control: no-cache"