The Keycloak Benchmark repository contains the necessary tools to run performance tests of a Keycloak server.
It has the following goals:
-
Setup Keycloak for reproducible results.
-
Run load tests against any Keycloak instance.
-
Use an observability stack to analyze test runs.
The repository has multiple modules that can be used together or separately to achieve this:
-
The benchmark module contains load tests based on Gatling.
-
The provisioning module contains a more advanced Kubernetes setup based on minikube, and docker-compose scripts for a simpler setup. The setup for minikube contains a Grafana based observability stack while the docker-compose based setup doesn’t.
-
The dataset module contains a Keycloak add-on that can create entities in a Keycloak data store to prepare it for a load test.
This main
branch Keycloak benchmark works with the Keycloak nightly versions,
for specific Keycloak release-based binaries please look at
https://github.com/keycloak/keycloak-benchmark/releases.
Read more on how to use it on https://www.keycloak.org/keycloak-benchmark/