infinispan/infinispan — pull request #2091 by galderz (2013-09-23 07:46:42+00:00)
Title: ISPN-3345 Track installed cache managers and pass to cache resolver

https://issues.jboss.org/browse/ISPN-3345

* No more unnecessary cache managers are created
* Add method to return installed embedded cache managers
* Add public Set getInstalledEmbeddedCacheManagers(BeanManager beanManager)

Thanks to @pmuir for finding a workaround to avoid leading cache managers. I slightly tweaked his fix to determine which was the default cache manager.