Skip to content

Commit 28fdb97

Browse files
authored
Updated default cache stack and related documentation on it in the readme (#856)
Signed-off-by: Jimmy Bourque <[email protected]>
1 parent 644873d commit 28fdb97

File tree

2 files changed

+16
-3
lines changed

2 files changed

+16
-3
lines changed

charts/keycloakx/README.md

Lines changed: 15 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -360,12 +360,25 @@ extraEnv: |
360360
For high availability, Keycloak must be run with multiple replicas (`replicas > 1`).
361361
The chart has a helper template (`keycloak.serviceDnsName`) that creates the DNS name based on the headless service.
362362

363-
#### DNS_PING Service Discovery
363+
### Default Cache Stack
364364

365-
JGroups discovery via DNS_PING is enabled by default but needs an additional JVM setting, which can be configured as follows:
365+
The default cache stack is now using `jdbc-ping` which leverages a table called `jgroups_ping` in the keycloak database to store the cache and significantly reduces network complexity. Keycloak has set this [transport stack](https://www.keycloak.org/server/caching#_transport_stacks) as the default starting in 26.1.0 and it is backwards compatible with all 26.X releases.
366+
367+
It is recommended to use the new default value as it works in kubernetes and across multiple cloud providers alike. Currently all other options have been marked as deprecated. However, if the original value of `kubernetes` is required in a given environment, it can still be set by using a custom stack:
368+
369+
```yaml
370+
cache:
371+
stack: custom
372+
```
373+
374+
Addtionally, the following environment variables would need to be added for it to function properly:
366375

367376
```yaml
368377
extraEnv: |
378+
- name: KC_CACHE
379+
value: "ispn"
380+
- name: KC_CACHE_STACK
381+
value: "kubernetes"
369382
- name: JAVA_OPTS_APPEND
370383
value: >-
371384
-Djgroups.dns.query={{ include "keycloak.fullname" . }}-headless

charts/keycloakx/templates/statefulset.yaml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ spec:
9797
- name: KC_CACHE
9898
value: "ispn"
9999
- name: KC_CACHE_STACK
100-
value: "kubernetes"
100+
value: "jdbc-ping"
101101
{{- end }}
102102
{{- if .Values.proxy.enabled }}
103103
- name: KC_PROXY_HEADERS

0 commit comments

Comments
 (0)