So in EhCache we have three major classes:
Cache,CacheManager, andStore
Under a replicated setup, which of these is actually being replicated? The Cache, the CacheManager or the Store? Calling a Cache‘s cache(K,V) method places that entry into whatever underlying Store it has been configured with (memory, disk, etc.), but then what replicated mechanism syncs this entry with other replicated mechanisms?
Once I understand that, I will be able to understand how those same “replicated mechanisms” change roles when we have a distributed cache configured. So my next question would be: under what circumstances would one choose replicated over distributed? Distributed seems to be the more powerful option all the way.
Final question: is replication and/or distribution available in the open source EhCache distro? From the documentation I can’t tell if EhCache uses the term “enterprise” as a synonym for “proprietary” or “licensed”.
Both replicated & distributed Ehcache are OSS. Enterprise comes with other features such as BigMemory & Active-Active Terracotta Server Array for example.
Replicated does its best at replicating all data to all nodes, while distributed does … distribute the data across all nodes, while keeping the data that is relevant to your a particular node on it (as far as resources allow). Also atomic operations and the like are only available using distributed caches.