Diego Lovison created ISPN-10235:
------------------------------------
Summary: Allow SpringRemoteCacheManager create a cache in runtime with the
default or a provided template
Key: ISPN-10235
URL:
https://issues.jboss.org/browse/ISPN-10235
Project: Infinispan
Issue Type: Enhancement
Affects Versions: 10.0.0.Beta3
Reporter: Diego Lovison
When working in a Spring app we can provide a cache name and Spring will create that cache
in Runtime. When using Remote Infinispan Spring Cache Support the exception will throw
{noformat}
org.infinispan.client.hotrod.exceptions.HotRodClientException:
org.infinispan.server.hotrod.CacheNotFoundException
{noformat}
This is because SpringRemoteCacheManager support only getCache
{code:java}
public SpringCache getCache(String name) {
RemoteCache<Object, Object> nativeCache =
this.nativeCacheManager.getCache(name);
return new SpringCache(nativeCache, this.readTimeout, this.writeTimeout);
}
{code}
We could allow the developer specify a boolean value like: createRemoteCacheInRuntime=true
and defaultRemoteCacheTemplate=myTemplate
In this case when adding @Cacheable("books") the books cache will be created
based on the specified arguments
--
This message was sent by Atlassian Jira
(v7.12.1#712002)