(WildFly 23)
I have the following situation:
- Two WildFly instances, clustered with jgroups
- The first one starts up, then an additional ear gets deployed after startup which puts something in the replicated-cache
- The second one starts up, but before the additional ear is deployed, it already initializes the replicated-cache which throws an error because the class in the cache does not exist yet
Caused by: org.jboss.modules.ModuleNotFoundException: deployment.myOtherModule.ear
So according to the documentation, the default mode for a replicated cache is 'LAZY'' (though this property is deprecated), which implies it should lazy load the first time it's being interacted with. But this is not true, it always starts up at the same time early on before I write or read anything.
This means that anything you put in the cache in an ear that starts later, will cause an error, even if you don't even read from the cache until that ear is deployed.
Is there anything I can do about this? There's no real way for me to realistically move the code to the ear that starts first. Is it a bug that it's not lazy loading the cache as one would expect?