-
1. Re: AS7 with Infinispan 5.1.4 and Tree API not working
galder.zamarreno May 4, 2012 3:43 AM (in response to michael_gronau)Can you post the client code that's interacting with the treecache? We have plenty examples of tree module working in https://github.com/infinispan/infinispan/tree/master/tree/src/test/java
-
2. Re: AS7 with Infinispan 5.1.4 and Tree API not working
michael_gronau May 4, 2012 3:51 AM (in response to michael_gronau)Hello Galder,
the Problem with the current version is that the creation of the TreeCache instance failes.
First i get a normal Cache instance from the CacheContainer with:
org.infinispan.Cache<String, Object> infiniCache = this.cacheContainer.getCache("mycachegoeshere");
then I try to create a new TreeCache instance:
TreeCache<String, Object> tc = new TreeCacheFactory().createTreeCache(infiniCache)
This failes with 5.1.4 because of the 'instanceof' check in AbstractDelegatingCacheImpl:
if (cache instanceof CacheImpl) this.cache = (CacheImpl<K, V>) cache; else throw new IllegalArgumentException("This adapter only works with CacheImpl, not with " + cache.getClass().getSimpleName()); This is because the cache I got from the container is not an instance of type CacheImpl but AbstractDelegatingCache.
Thanks alot,
Michael
-
3. Re: AS7 with Infinispan 5.1.4 and Tree API not working
darrenjones May 25, 2012 5:07 AM (in response to michael_gronau)I am seeing this too - JBoss AS7 does not seem to be using CacheImpl for container-configured caches.
Perhaps this is more of an AS7 issue? Is there a way to get AS7 to create CacheImpl caches?
-
4. Re: AS7 with Infinispan 5.1.4 and Tree API not working
michael_gronau May 25, 2012 9:22 AM (in response to darrenjones)Hi Darren,
this bug will be fixed with infinispan 5.1.5Final.