Metrics
The KeySafe 5 metrics endpoints return metrics in OpenMetrics text format (HTTP content-type "application/openmetrics-text"). This format is defined by the OpenMetrics Specification.
The following metric endpoints are available in this release of KeySafe 5.
Endpoint | Minimum KeySafe 5 version | Description | Metric Labels |
---|---|---|---|
/codesafe/v1/metrics |
1.2 |
SEE Machine statistics for all running CodeSafe 5 machines |
|
Integrations
Data from KeySafe 5 metrics endpoints can be imported into any observability tool capable of consuming the OpenMetrics format.
For most tools this consists of configuring your tooling to poll the metrics HTTP endpoint at a certain interval by providing the API endpoint to query along with any necessary authentication.
This section provides basic guidance for a selection of common tools. For more detailed instructions, consult the documentation for your specific tooling.
Prometheus
For Prometheus you must configure a scrape config
to directly consume the KeySafe 5 metrics data into Prometheus.
An example scrape config for polling an unauthenticated KeySafe 5 CodeSafe metrics endpoint:
scrape_configs:
- job_name: KeySafe 5 CodeSafe
scrape_interval: 300s
static_configs:
- targets: ["example.keysafe5deployment.com"]
metrics_path: "/codesafe/v1/metrics"
scheme: https
Elastic Stack
Integration with the Elastic Stack (Elasticsearch and Kibana) can be achieved by using the OpenMetrics integration within Kibana. This involves configuring Metricbeat to report the metrics data to Elasticsearch via polling the KeySafe 5 metrics endpoint.
For more details, search for OpenMetrics in Elastic integrations or follow the step-by-step OpenMetrics integration guide within Kibana.
Splunk
For Splunk there is not currently a direct OpenMetrics integration. One possible approach is to configure an HTTP Event Collector and use an intermediary script to poll the KeySafe 5 metrics endpoint, then translate the API responses from KeySafe 5 into a format that can be submitted to the HTTP Event Collector endpoint in Splunk.