Monitoring
Logging
Relay produces logs to the standard error stream (stderr
), with INFO
logging level by default.
For example, after starting Relay you may see output such as this:
INFO relay::setup > launching relay from config folder .relay
INFO relay::setup > relay mode: managed
INFO relay::setup > relay id: cde0d72e-0c4e-4550-a934-c1867d8a177c
INFO relay::setup > log level: INFO
This example displays the messages with the default logging level (INFO
), which you can modify so it displays either more or less information. For details about configuring logging please see the Logging section on the options page.
Error Reporting
By default, Relay logs errors to the configured logger. You can enable error reporting to your
sentry:
enabled: true
dsn: <your_dsn>
More information about available options and their meaning can be found on the options page.
Health Checks
Relay provides two URLs for checking system status:
GET /api/relay/healthcheck/live/
: Tests if Relay is running and listening to HTTP requests.GET /api/relay/healthcheck/ready/
: Tests if Relay is authenticated with the upstream and operating normally.
Both endpoints return a 200 OK response when successful:
{
"is_healthy": true
}
Metrics
You can submit stats to a StatsD server by configuring the metrics.statsd
key to an ip:port
tuple.
Example Configuration
metrics:
# Endpoint of your StatsD server
statsd: 127.0.0.1:8126
# Prefix all metric names with this string
prefix: mycompany.relay
The options for configuring metrics reporting are documented on the options page.
Learn More
Our documentation is open source and available on GitHub. Your contributions are welcome, whether fixing a typo (drat!) or suggesting an update ("yeah, this would be better").