Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Kubernetes cache-stack documentation update #10341

Closed
vanrar68 opened this issue Feb 20, 2022 · 4 comments · Fixed by #10425
Closed

Kubernetes cache-stack documentation update #10341

vanrar68 opened this issue Feb 20, 2022 · 4 comments · Fixed by #10425
Labels
area/dist/quarkus kind/bug Categorizes a PR related to a bug
Milestone

Comments

@vanrar68
Copy link
Contributor

vanrar68 commented Feb 20, 2022

Describe the bug

Keycloak "Configuring distributed cache" guide states that:

The following table shows transport stacks that are available without any further configuration than using the --cache-stack build option:
- tcp
- udp
- kubernetes

When running keycloak 17.0.0 built with --cache-stack=kubernetes on a Kubernetes cluster the following error is thrown:

2022-02-20 19:42:39,604 INFO  [org.infinispan.CONTAINER] (keycloak-cache-init) ISPN000128: Infinispan version: Infinispan 'Triskaidekaphobia' 13.0.5.Final
2022-02-20 19:42:39,711 INFO  [org.infinispan.CLUSTER] (keycloak-cache-init) ISPN000078: Starting JGroups channel `ISPN`
2022-02-20 19:42:40,401 ERROR [org.keycloak.quarkus.runtime.cli.ExecutionExceptionHandler] (main) ERROR: Failed to start server in (production) mode
2022-02-20 19:42:40,402 ERROR [org.keycloak.quarkus.runtime.cli.ExecutionExceptionHandler] (main) ERROR: Failed to start caches
2022-02-20 19:42:40,402 ERROR [org.keycloak.quarkus.runtime.cli.ExecutionExceptionHandler] (main) ERROR: org.infinispan.manager.EmbeddedCacheManagerStartupException: org.infinispan.commons.CacheConfigurationException: ISPN000085: Error while trying to create a channel using the specified configuration file: default-configs/default-jgroups-kubernetes.xml
2022-02-20 19:42:40,402 ERROR [org.keycloak.quarkus.runtime.cli.ExecutionExceptionHandler] (main) ERROR: org.infinispan.commons.CacheConfigurationException: ISPN000085: Error while trying to create a channel using the specified configuration file: default-configs/default-jgroups-kubernetes.xml
2022-02-20 19:42:40,403 ERROR [org.keycloak.quarkus.runtime.cli.ExecutionExceptionHandler] (main) ERROR: ISPN000085: Error while trying to create a channel using the specified configuration file: default-configs/default-jgroups-kubernetes.xml
2022-02-20 19:42:40,404 ERROR [org.keycloak.quarkus.runtime.cli.ExecutionExceptionHandler] (main) ERROR: dns_query can not be null or empty
2022-02-20 19:42:40,404 ERROR [org.keycloak.quarkus.runtime.cli.ExecutionExceptionHandler] (main) For more details run the same command passing the '--verbose' option. Also you can use '--help' to see the details about the usage of the particular command.

Version

17.0.0

Expected behavior

No response

Actual behavior

No response

How to Reproduce?

No response

Anything else?

No response

@vanrar68 vanrar68 added kind/bug Categorizes a PR related to a bug status/triage labels Feb 20, 2022
@JingJCV
Copy link

JingJCV commented Feb 22, 2022

As the log suggested, you need to pass jgroups.dns.query value to keycloak. This is a required property.
https://infinispan.org/docs/dev/titles/embedding/embedding.html#kubernetes
I did it like this #10359 but not sure the better way.

@vanrar68
Copy link
Contributor Author

Ok thanks. I guess the statement "without any further configuration" in the Keycloak guide isn't really accurate. Maybe someone from the team can move this issue over to keycloak-documentation

@vanrar68
Copy link
Contributor Author

vanrar68 commented Feb 22, 2022

I added the jgroups.dns.query property with the value pointing to the keycloak-headless service FQDN and it worked.
I opened issue 1416 on the keycloak-documentation repository

@vanrar68 vanrar68 changed the title Kubernetes cache-stack error Kubernetes cache-stack documentation update Feb 23, 2022
@vanrar68
Copy link
Contributor Author

Turns out the cluster/cache guide is part of the keycloak project and not the keycloak-documentation project. Will push a PR that fixes the doc

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area/dist/quarkus kind/bug Categorizes a PR related to a bug
Projects
Development

Successfully merging a pull request may close this issue.

4 participants