<div dir="ltr"><div><div><div><div><div><div><div>Hi,<br><br></div>We&#39;re in the process of assessing the impact on upgrading from Keycloak 1.2.0 to 1.6.1. We came across an issue when trying to enable Infinispan cache through the keycloak-server.json file as we used to do in 1.2.0.<br><br></div>We have the following entries in 1.6.1:<br>    &quot;realm&quot;: {<br>        &quot;provider&quot;: &quot;infinispan&quot;<br>    },<br><br>    &quot;user&quot;: {<br>        &quot;provider&quot;: &quot;infinispan&quot;<br>    },<br><br>    &quot;userSessionPersister&quot;: {<br>        &quot;provider&quot;: &quot;infinispan&quot;<br>    },<br>.........<br>    &quot;connectionsInfinispan&quot;: {<br>        &quot;default&quot; : {<br>            &quot;cacheContainer&quot; : &quot;java:comp/env/infinispan/Keycloak&quot;<br>        }<br>    }<br><br></div>All configurations in 1.6.1 standalone-ha.xml file remains comparable (and correct to the best of our knowledge) with the ones in 1.2.0.<br><br></div>With the above configs, when we start the Keycloak service the following error(s) get logged:<br><br>18:03:31,610 ERROR [org.jboss.msc.service.fail] (ServerService Thread Pool -- 64) MSC000001: Failed to start service jboss.undertow.deployment.default-server.default-host./auth: org.jboss.msc.service.StartException in service jboss.undertow.deployment.default-server.default-host./auth: java.lang.RuntimeException: Failed to construct public org.keycloak.services.resources.KeycloakApplication(javax.servlet.ServletContext,org.jboss.resteasy.core.Dispatcher)<br>    at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:85)<br>    at java.util.concurrent.Executors$RunnableAdapter.call(Executors.java:471) [rt.jar:1.7.0_45]<br>    at java.util.concurrent.FutureTask.run(FutureTask.java:262) [rt.jar:1.7.0_45]<br>    at java.util.concurrent.ThreadPoolExecutor.runWorker(ThreadPoolExecutor.java:1145) [rt.jar:1.7.0_45]<br>    at java.util.concurrent.ThreadPoolExecutor$Worker.run(ThreadPoolExecutor.java:615) [rt.jar:1.7.0_45]<br>    at java.lang.Thread.run(Thread.java:744) [rt.jar:1.7.0_45]<br>    at org.jboss.threads.JBossThread.run(JBossThread.java:320) [jboss-threads-2.2.0.Final.jar:2.2.0.Final]<br>Caused by: java.lang.RuntimeException: Failed to construct public org.keycloak.services.resources.KeycloakApplication(javax.servlet.ServletContext,org.jboss.resteasy.core.Dispatcher)<br>    at org.jboss.resteasy.core.ConstructorInjectorImpl.construct(ConstructorInjectorImpl.java:160)<br>    at org.jboss.resteasy.spi.ResteasyProviderFactory.createProviderInstance(ResteasyProviderFactory.java:2211)<br>    at org.jboss.resteasy.spi.ResteasyDeployment.createApplication(ResteasyDeployment.java:295)<br>    at org.jboss.resteasy.spi.ResteasyDeployment.start(ResteasyDeployment.java:236)<br>    at org.jboss.resteasy.plugins.server.servlet.ServletContainerDispatcher.init(ServletContainerDispatcher.java:112)<br>    at org.jboss.resteasy.plugins.server.servlet.HttpServletDispatcher.init(HttpServletDispatcher.java:36)<br>    at io.undertow.servlet.core.LifecyleInterceptorInvocation.proceed(LifecyleInterceptorInvocation.java:117)<br>    at org.wildfly.extension.undertow.security.RunAsLifecycleInterceptor.init(RunAsLifecycleInterceptor.java:78)<br>    at io.undertow.servlet.core.LifecyleInterceptorInvocation.proceed(LifecyleInterceptorInvocation.java:103)<br>    at io.undertow.servlet.core.ManagedServlet$DefaultInstanceStrategy.start(ManagedServlet.java:230)<br>    at io.undertow.servlet.core.ManagedServlet.createServlet(ManagedServlet.java:131)<br>    at io.undertow.servlet.core.DeploymentManagerImpl.start(DeploymentManagerImpl.java:511)<br>    at org.wildfly.extension.undertow.deployment.UndertowDeploymentService.startContext(UndertowDeploymentService.java:101)<br>    at org.wildfly.extension.undertow.deployment.UndertowDeploymentService$1.run(UndertowDeploymentService.java:82)<br>    ... 6 more<br>Caused by: java.lang.RuntimeException: Failed to find provider infinispan for realm<br>    at org.keycloak.services.DefaultKeycloakSessionFactory.init(DefaultKeycloakSessionFactory.java:66)<br>    at org.keycloak.services.resources.KeycloakApplication.createSessionFactory(KeycloakApplication.java:162)<br>    at org.keycloak.services.resources.KeycloakApplication.&lt;init&gt;(KeycloakApplication.java:62)<br>    at sun.reflect.NativeConstructorAccessorImpl.newInstance0(Native Method) [rt.jar:1.7.0_45]<br>    at sun.reflect.NativeConstructorAccessorImpl.newInstance(NativeConstructorAccessorImpl.java:57) [rt.jar:1.7.0_45]<br>    at sun.reflect.DelegatingConstructorAccessorImpl.newInstance(DelegatingConstructorAccessorImpl.java:45) [rt.jar:1.7.0_45]<br>    at java.lang.reflect.Constructor.newInstance(Constructor.java:526) [rt.jar:1.7.0_45]<br>    at org.jboss.resteasy.core.ConstructorInjectorImpl.construct(ConstructorInjectorImpl.java:148)<br>    ... 19 more<br><br><br></div>Is the new way to enable Infinispan different to what we had earlier? If so, can someone please point out the correct way?<br><br><br></div>Regards,<br></div>Lohitha.<br><div><div><div><div><div><br><div><br></div></div></div></div></div></div></div>