| 1. It's not a question whether this should be possible (it should IMO), but whether this should work without any extra effort (setting CacheKeysFactory). IMO, for the end user the best effect can be achieved when default configuration fails with error suggesting to use CacheKeysFactory that includes entity type in the CacheKey (in other words, the error should suggest the user to set `hibernate.cache.infinispan.cachekeysfactory=with-type` where `with-type` - or similar string - is a shortcut for the actual class). 2. The SPI and common code could allow that configuration (by "could" I mean that I don't have any objections against common code not failing such configuration). The implementation can fail the configuration, though. |