Is it possible to implement distributed caching using of Ehcache without Terracotta Enterprise Suite?

十年热恋 提交于 2019-12-12 08:33:22

问题


I try to find how to implement distributed caching for applications.

Ehcache already used for caching in my project, that's why I search how to solve this issue using it. But, unfortunately, it seems, that Terracotta Enterprise Suite is needed for this and it is commercial. Isn't it? Is there another solution how to use Ehcache for distributed caching (RMI or anything else)?


回答1:


You don't need terracotta enterprise suite to cluster you Ehcache instances. So you can use clustering with Ehcache & Terracotta today, with pure OSS :

http://www.ehcache.org/documentation/configuration/distributed-cache-configuration

Edit: This link has expired. Below is the new link related to clustered cache http://www.ehcache.org/documentation/3.4/clustered-cache.html

Now if you need replication, you can use other mechanisms like RMI indeed :

http://www.ehcache.org/documentation/replication/index

Though, only the Terracotta clustering would bring you HA and features like consistency guarantees and the like...




回答2:


You may want to try Hazelcast as well. It is open source, distributed cache and is super easy to use.

PS: I work for Hazelcast




回答3:


there are different ways to implement distributed cache using ehcache mechanism. One can be using RMI or Jgroups.

In one of the project i came through same situation and after some research i figured out Using Redis server for cache management is a easy and effective solution.

I suggesting this as a answer because if you try using ehcache it will take time and increase complexity and you can have multiple cache manager in your workspace.



来源:https://stackoverflow.com/questions/9992899/is-it-possible-to-implement-distributed-caching-using-of-ehcache-without-terraco

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!