Query for the status of an instance.
The status code 503 is used to indicate to load balancers that a service is not available for requests right now.
$ curl -XGET http://localhost:8080/status
{
"ok": true,
"service": {
"name": "The Heroic Time Series Database",
"version": "master (git: aaccddee)",
"id": "api"
},
"consumers": {
"ok": true,
"available": 0,
"ready": 0,
"errors": 0,
"consumingThreads": 1,
"totalThreads": 1
},
"backends": {
"ok": true,
"available": 0,
"ready": 0
},
"metadataBackends": {
"ok": true,
"available": 0,
"ready": 0
},
"cluster": {
"ok": true,
"onlineNodes": 1,
"offlineNodes": 0
}
}
A 503 will still return a response body, however the root key .ok
will have the value false
.
The below document shows that there is something wrong with the configured consumers, in this case it is because the number of consumingThreads
is not the same as the totalThreads
{
"ok": false,
"consumers": {
"ok": false,
"available": 0,
"ready": 0,
"errors": 0,
"consumingThreads": 0,
"totalThreads": 1
},
...
}