[jboss-jira] [JBoss JIRA] (WFLY-4562) Deprecate Infinispan container/cache start mode

Sean Flanigan (JIRA) issues at jboss.org
Thu May 7 22:19:45 EDT 2015


    [ https://issues.jboss.org/browse/WFLY-4562?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=13066408#comment-13066408 ] 

Sean Flanigan commented on WFLY-4562:
-------------------------------------

Without {{start="EAGER"}}, how can I make sure a cache container will be there when I look it up in JNDI?  Our application does the JNDI lookup at startup, so that we can detect missing cache configuration during deployment, but without {{start="EAGER"}} it fails:

{noformat}
Caused by: javax.naming.NameNotFoundException: infinispan/container/zanata [Root exception is java.lang.IllegalStateException]
	at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:153)
	at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:83)
	at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:207)
	at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:184)
	at org.jboss.as.naming.InitialContext$DefaultInitialContext.lookup(InitialContext.java:237)
	at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:193)
	at org.jboss.as.naming.NamingContext.lookup(NamingContext.java:189)
	at javax.naming.InitialContext.lookup(InitialContext.java:411)
	at javax.naming.InitialContext.lookup(InitialContext.java:411)
	at org.zanata.util.ServiceLocator.getJndiComponent(ServiceLocator.java:82)
	at org.zanata.cache.CacheContainerProducer.initialize(CacheContainerProducer.java:56)
	... 38 more
Caused by: java.lang.IllegalStateException
	at org.jboss.msc.value.InjectedValue.getValue(InjectedValue.java:47)
	at org.jboss.as.naming.service.BinderService.getValue(BinderService.java:138)
	at org.jboss.as.naming.service.BinderService.getValue(BinderService.java:46)
	at org.jboss.msc.service.ServiceControllerImpl.getValue(ServiceControllerImpl.java:1158)
	at org.jboss.as.naming.ServiceBasedNamingStore.lookup(ServiceBasedNamingStore.java:131)
	... 48 more
{noformat}

Is the best solution for this to declare a {{<resource-ref>}} in {{jboss-web.xml}} ?

> Deprecate Infinispan container/cache start mode
> -----------------------------------------------
>
>                 Key: WFLY-4562
>                 URL: https://issues.jboss.org/browse/WFLY-4562
>             Project: WildFly
>          Issue Type: Enhancement
>          Components: Clustering
>    Affects Versions: 9.0.0.Beta2
>            Reporter: Paul Ferraro
>            Assignee: Paul Ferraro
>             Fix For: 9.0.0.CR1
>
>
> start="EAGER" was only added to the Infinispan subsystem for use by JDG - so that a given container or cache service would install as ACTIVE rather than ON_DEMAND.  In the context of WildFly, we would never want this since the modules referenced by cache entries may not yet be loaded.  Many users configure start="EAGER" and inevitably have issues during redeploy. Consequently, we should drop this from the subsystem XSD altogether and deprecate it from the model.
> Effectively, only start="LAZY" will be supported.



--
This message was sent by Atlassian JIRA
(v6.3.15#6346)


More information about the jboss-jira mailing list