Ready reference
Use Sensu’s /ready API endpoint to confirm whether a Sensu instance is ready to serve API requests and accept agent connections.
A request to the /ready backend API endpoint retrieves a text response with information about whether your Sensu instance is ready to serve API requests. Here’s an example request to the /ready API endpoint:
curl -X GET \
http://127.0.0.1:8080/readyA request to the /ready agent transport API endpoint via the backend WebSocket retrieves information about whether your Sensu instance is ready to accept agent connections. Here’s an example request to the /ready agent transport API endpoint using the default WebSocket port 8081:
curl -X GET \
http://127.0.0.1:8081/readyReady response example
The following response means that the Sensu instance is ready to serve API requests or accept agent connections:
readyNot ready response examples
To help prevent instability during sensu-backend startup, use the api-serve-wait-time and agent-serve-wait-time backend configuration options.
Use api-serve-wait-time to configure a delay after startup before the backend API will serve traffic.
Until the specified duration expires, the text response body will state that the API is unavailable:
API unavailable during startup.
See api-serve-wait-time settings.Use agent-serve-wait-time to configure a delay after startup before the agent listener will begin accepting agent connections.
Until the specified duration expires, the text response body will state that agentd is unavailable:
agentd temporarily unavailable during startupNot-ready responses include a Retry-After header that lists the specified api-serve-wait-time or agent-serve-wait-time duration.