[infinispan-issues] [JBoss JIRA] (ISPN-1847) treecache Exception "invocationBatching is not enabled" with configured batching="true" in AS7 infinispan subsystem
Lars Fischer (JIRA)
jira-events at lists.jboss.org
Tue Feb 7 10:38:48 EST 2012
Lars Fischer created ISPN-1847:
----------------------------------
Summary: treecache Exception "invocationBatching is not enabled" with configured batching="true" in AS7 infinispan subsystem
Key: ISPN-1847
URL: https://issues.jboss.org/browse/ISPN-1847
Project: Infinispan
Issue Type: Bug
Components: Tree API
Affects Versions: 5.1.1.FINAL
Reporter: Lars Fischer
Assignee: Manik Surtani
Hello,
trying to get the treecache working inside a JBoss AS7 7.1.0-x, there is a problem within the configuration parameter "invocationBatching". Although batching is enabled, treecache is not recognizing it.
I think the reason is that treecache is using the deprecated configuration API. (e.g. TreeCacheFactory#createTreeCache)
AS7 cache configurations:
{code}
<cache-container name="myappCache" default-cache="repl">
<local-cache name="default" batching="true">
<eviction strategy="LRU"/>
</local-cache>
<distributed-cache mode="SYNC" name="repl" batching="true">
<locking isolation="REPEATABLE_READ"/>
</distributed-cache>
</cache-container>
...
{code}
Example usage:
{code}
@Singleton
public class CacheServiceBean {
@Resource(mappedName = "java:jboss/infinispan/myappCache")
CacheContainer infinispanCacheContainer;
TreeCache tc;
@PostConstruct
public void init(){
this.tc = new TreeCacheFactory().createTreeCache(infinispanCacheContainer.getCache());
}
}
{code}
Resulting exception:
{quote}
org.infinispan.config.ConfigurationException: invocationBatching is not enabled. Make sure this is enabled by calling config.setInvocationBatchingEnabled(true)
at org.infinispan.tree.TreeCacheFactory.createTreeCache(TreeCacheFactory.java:55) [infinispan-tree-5.1.0.CR1.jar:5.1.0.CR1]
at com......CacheServiceBean.init(CacheServiceBean.java:35) [example-base-ejb-0.0.1-SNAPSHOT.jar:]
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method) [:1.6.0_29]
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39) [:1.6.0_29]
at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25) [:1.6.0_29]
at java.lang.reflect.Method.invoke(Method.java:597) [:1.6.0_29]
at org.jboss.as.ee.component.ManagedReferenceLifecycleMethodInterceptorFactory$ManagedReferenceLifecycleMethodInterceptor.processInvocation(ManagedReferenceLifecycleMethodInterceptorFactory.java:130) [jboss-as-ee-7.1.0.Final-SNAPSHOT.jar:7.1.0.Final-SNAPSHOT]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.WeavedInterceptor.processInvocation(WeavedInterceptor.java:53) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.weld.injection.WeldInjectionInterceptor.processInvocation(WeldInjectionInterceptor.java:73) [jboss-as-weld-7.1.0.Final-SNAPSHOT.jar:7.1.0.Final-SNAPSHOT]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
at org.jboss.as.ee.component.ManagedReferenceFieldInjectionInterceptorFactory$ManagedReferenceFieldInjectionInterceptor.processInvocation(ManagedReferenceFieldInjectionInterceptorFactory.java:112) [jboss-as-ee-7.1.0.Final-SNAPSHOT.jar:7.1.0.Final-SNAPSHOT]
at org.jboss.invocation.InterceptorContext.proceed(InterceptorContext.java:288) [jboss-invocation-1.1.1.Final.jar:1.1.1.Final]
{quote}
--
This message is automatically generated by JIRA.
If you think it was sent incorrectly, please contact your JIRA administrators: https://issues.jboss.org/secure/ContactAdministrators!default.jspa
For more information on JIRA, see: http://www.atlassian.com/software/jira
More information about the infinispan-issues
mailing list