Details
-
Bug
-
Resolution: Done
-
Major
-
5.0.0.CR8, 5.0.0.FINAL
-
None
Description
The following thing is allowed by the CDI extension.
class Config { @Infinispan("greeting-cache") @GreetingCache @Produces Configuration greetingCacheConfiguration; }
If the cache configuration is not provided by an external mechanism (e.g. with an XML configuration file) the cache configuration is not registered. When this cache will be injected the default configuration of the corresponding cache manager will be used (see behavior of CacheContainer#getCache(name)).
To be consistent the cache configuration must be registered with a clone of the default configuration. In this case the EmbeddedCacheManager#getCacheNames return will reflect the "Config" class content.