1

I've been researching this for a week now, but I'd like some thoughts on my particular situation...

2 physical servers:

  • Server A - public WAR, admin WAR

  • Server B - public WAR

Requirements:

  • Both WARs need to view the same data.

  • admin WAR modifies / adds data to the cache.

  • public WARs modify other parts of the cache / add data to it.

  • entire cache needs to reside in memory on each physical server (if I add something on Server A admin WAR or public WAR, it needs to show up on Server B public WAR) so in the event of a failure, we aren't waiting for half the cache to be populated

  • 1,500 active users/server, vast majority of traffic is read, very little write

Additional hardware is out of the question.

Is there a good third party caching solution for this scenario? It seems most distributed caching systems want to leave half the data on Server A and half on Server B, which wouldn't meet our failover performance needs.

Thanks for any ideas!

0

6 Answers 6

1

You should look at Redis

Sign up to request clarification or add additional context in comments.

Comments

1

http://www.gigaspaces.com/ has a solution for that, it allows you to create "Space" that serves as cache in replicated mode, so each node will have exact copy of data.

They also have solution for fail-over or hot stand by.

Edit: Gigaspace is far more than just a shared cache, but you can use just the caching solution. It's called In memory data grid. They have dramaticaly changed they web pages so I can't find exact page. But if you search through the documentation yo'll find it.

You can start here http://www.gigaspaces.com/datagrid

But the technology is not free.

1 Comment

Doesn't work for this problem domain unfortunately. This is for custom software sold to companies that host it themselves on existing machines (new version of existing software, for existing hardware.. web hosting not an option).
0

Take a look at the replicated options for EhCache.

Sounds like you've been searching for information on "distributed caches", which has a different defintion than "replicated cache". A distributed cache is a larger cache system spread out among many machines, so that the loss of anyone machine in the cluster does not bring down the entire cache, but just a portion. In this scenario the total size of your cache can reach (number of machines times memory of each machine).

In a replicated cache, the cached data is replicated across each machine, limiting you to a total cache size of max(memory of any one machine).

1 Comment

You're right. I'm reading the replication details for EhCache now. Thank you!
0

It seems most distributed caching systems want to leave half the data on Server A and half on Server B, which wouldn't meet our failover performance needs.

No, you can tweak it easy. Otherwise you need sticky seesion (you have to know exactly, which cache stores your data). You can choose any solution on the market EhCache, GigaSpace, GridGain etc. I would recommend to use JBoss Cache, imho the simplest and exactly what you need

Comments

0

There are many solutions in this space.

All of them can be configured as distributed caches. AFAIK Infinispan works best when left an an embedded cache in JBoss AS, last I checked it was difficult to integrate into other app servers. If you have money I would recommend BigMemory from Terracotta. Its the commercial derivative of EhCache and provides alot of additional nice-to-have features.

Comments

0

We use Apache Commons JCS and have been very pleased with it. It claims to be almost twice as fast as EHCache. For the situation you have described, you would probably configure a Lateral TCP Cache.

Comments

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.