git clone -b BRANCH_FROM_STEP_1 https://github.com/keycloak/keycloak-grafana-dashboard.git
Keycloak provides metrics to observe what is happening inside the deployment. To understand how metrics evolve over time, it is helpful to collect them and visualize in graphs.
This guide provides instructions on how to visualize collected Keycloak metrics in a running Grafana instance.
Keycloak metrics are enabled. Follow Enabling Keycloak Metrics guide for more details.
Grafana instance is running and Keycloak metrics are collected into a Prometheus instance.
Grafana dashboards are distributed in the form of a JSON file that is imported into a Grafana instance. JSON definitions of Keycloak Grafana dashboards are available in the keycloak/keycloak-grafana-dashboard GitHub repository.
Follow these steps to download JSON file definitions.
Identify the branch from keycloak-grafana-dashboards
to use from the following table.
Keycloak version | keycloak-grafana-dashboards branch |
---|---|
>= 26.1 |
|
Clone the GitHub repository
git clone -b BRANCH_FROM_STEP_1 https://github.com/keycloak/keycloak-grafana-dashboard.git
The dashboards are available in the directory keycloak-grafana-dashboard/dashboards
.
The following sections describe the purpose of each dashboard.
This dashboard is available in the JSON file: keycloak-troubleshooting-dashboard.json
.
On the top of the dashboard, graphs display the service level indicators as defined in Keycloak service level indicators (SLIs). This dashboard can be also used while troubleshooting a Keycloak deployment following the Metrics for troubleshooting Keycloak deployment guide, for example, when SLI graphs do not show expected results.
This dashboard is available in the JSON file: keycloak-capacity-planning-dashboard.json
.
This dashboard shows metrics that are important when estimating the load handled by a Keycloak deployment. For example, it shows the number of password validations or login flows performed by Keycloak. For more detail on these metrics, see the guide Keycloak self-provided metrics.
Keycloak event metrics must be enabled for this dashboard to work correctly. To enable them, see the guide Enabling Keycloak Event Metrics. |