org.wildfly.clustering.infinispan.cache-configuration.ejb... is already registered in JBoss EAP 7.2 when deployment has SFSBs referencing more than 1 cache

Solution Unverified - Updated

Environment

Red Hat JBoss Enterprise Application Platform (EAP) 7.2

Issue

  • Our application is failing to deploy when we have Stateful Session EJBs using different caches ( @Cache ) in JBoss EAP 7.2
<caches>
<cache name="simple"/>
<cache name="infinispanCache" passivation-store-ref="infinispanStore" aliases="passivating"/>
<cache name="infinispanCache2" passivation-store-ref="infinispanStore2" aliases="longLife"/>
</caches>
<passivation-stores>
<passivation-store name="infinispanStore" cache-container="ejb" bean-cache="passivation" max-size="5"/>
<passivation-store name="infinispanStore2" cache-container="ejb" bean-cache="passivation" max-size="10"/>
</passivation-stores>
2019-01-10 12:14:10,757 ERROR [org.jboss.msc.service.fail] (MSC service thread 1-6) MSC000001: Failed to start service jboss.deployment.subunit."frameworktest.ear"."framework_ejb.jar".cache-dependencies-installer: org.jboss.msc.service.StartException in service jboss.deployment.subunit."frameworktest.ear"."framework_ejb.jar".cache-dependencies-installer: Failed to start service
at org.jboss.msc.service.ServiceControllerImpl$StartTask.execute(ServiceControllerImpl.java:1730)
[...]
Caused by: org.jboss.msc.service.DuplicateServiceException: Service org.wildfly.clustering.infinispan.cache-configuration.ejb.frameworktest.ear/framework_ejb.jar is already registered
at org.jboss.msc.service.ServiceRegistrationImpl.setInstance(ServiceRegistrationImpl.java:111)

Resolution

Apply the current JBoss EAP 7.2 cumulative patch (the issue is being fixed in CP1)

Root Cause

Content from issues.jboss.org is not included.JBEAP-16144

Components
Category

This solution is part of Red Hat’s fast-track publication program, providing a huge library of solutions that Red Hat engineers have created while supporting our customers. To give you the knowledge you need the instant it becomes available, these articles may be presented in a raw and unedited form.