Replies: 6 comments 5 replies
-
Hi @mhajas - I ran the Infinispan container via podman, and Keycloak Quarkus with Maven, and then got the following Exception continuously:
It seems to me that Infinispan advertises 10.0.2.100 as its public IP address, which is then unavailable for Keycloak to reach. Can I force Infinispan to advertise itself from a specific IP address (localhost)? |
Beta Was this translation helpful? Give feedback.
-
Is this information available somewhere in the official documentation? |
Beta Was this translation helpful? Give feedback.
-
Is there a way to completely disable cache-reindexing? Right now there seems to be a value 'all', which is the default, but no value for 'none'. So omitting the property doesnt help because then 'all' is used. |
Beta Was this translation helpful? Give feedback.
-
out of curiocity, is the performance of this new storage with hotrod compare with the legacy store? |
Beta Was this translation helpful? Give feedback.
-
also, presently i think there is no way to reuse an infinispan cluster for multiple keycloak deployments. |
Beta Was this translation helpful? Give feedback.
-
As announced to the community in this blog post, we are no longer developing the Map Store, and it will be removed from Keycloak's codebase. Follow #24111 for the removal steps. |
Beta Was this translation helpful? Give feedback.
-
Setup Keycloak server with the Infinispan server as storage
Setting up Infinispan server
Setup of an Infinispan server using either docker or podman:
Managing Infinispan server
There are two ways how to manage the Infinispan server. The first one is Infinispan
Server management console
; sign in with username and passwordadmin
.The other option is Infinispan CLI, available here: https://github.com/infinispan/infinispan-quarkus/releases/tag/13.0.10.Final
In the
zip
file there isinfinispan-cli
executable file. After executing a CLI environment is opened.For connecting to our Infinispan server one can write
connect
command which asks for a username and password (bothadmin
).Here is a link to CLI docs for more details.
Removing caches with CLI
my-cache
do the following:NOTE: it is also possible to remove caches in the
Server management console
.Running Keycloak with HotRod as its storage
WARNING: with the setup below, the Keycloak test server will only use the HotRod Storage for entities that have the storage implemented, and for others will use the concurrent hash map storage that stores information in
target/map
(No entities like this at the moment, but there will beevents
andsingleUseObjects
shortly).org.keycloak.testsuite.KeycloakServer
with the following parameters; the given properties will replace values in https://github.com/keycloak/keycloak/blob/main/testsuite/utils/src/main/resources/META-INF/keycloak-server.jsonkeycloak.connectionsHotRod.reindexCaches
parameter which will speed up the startup.Server management console
, or in infinispan cli, for example:Alternative setup with Quarkus
After building Keycloak, run
Or use the Keycloak nightly distribution or unpack the locally build file
quarkus/dist/target/keycloak-999-SNAPSHOT.zip
and runIndex data storing
By default, Infinispan stores index data in persistent storage instead of memory. The data stored in the caches are stored in memory. This can lead to inconsistency, for example, after container restart when indexed data survive restarting while cached data does not.
To avoid this Keycloak configures indexed data to be stored in memory too using the following cache config.
The relevant part is
storage="local-heap"
.Known issues and limitations
Summary:
Open issues
Beta Was this translation helpful? Give feedback.
All reactions