troubleshooting Question

Worried about stale data while using Microsofts Caching Application Block in a web farm

Avatar of whlply2
whlply2 asked on
.NET ProgrammingC#ASP.NET
7 Comments1 Solution376 ViewsLast Modified:
We are currently using Microsofts Caching Application Block (June 2005)  to cache items such as dropdownlist box options in a .NET 1.1 website.  We use the default Null Backing Store for the Caching Application block.  We recently moved to a web farm and are worried about stale data.  We are using load balancing in a round-robin fashion.  There are possibilities for stale data depending on which web farm node you hit.  I was told the enterprise library caching block does not support a web farm out of the box.  Should I modify the Microsoft Caching Application Block setup or do you recommend a 3rd party solution like NCache?  I'd prefer modifying the C.A.B. but if I have to purchase NCache I guess I have to.  I'm guessing many other developers have come across this problem.   Please let me know what you recommend.  Thanks in advance!

By the way, I asked Microsoft already and they recommended the following:
* Continue to use the June 2005 Enterprise Library with the Caching Application Block.
* Switch from the Null Backing Store to the Database Backing store.
* Set up a custom database notification with SQL Server 2005 notification services.  This will help notify the different web farm nodes to expire their cache if a change is made.
* Set a more realistic expiration policy.  We currently have expiration set to 10 minutes but 30 or 60 minutes would be better.  After all, one of the primary considerations for caching data is when the data doesnt change very often.  

One small caveat to this approach is there is still the possibility for a small staleness factor.  Our business sponsors will need to be aware of this factor and decide if its acceptable.  The Microsoft rep agreed.  

Should I stick with this Microsoft solution, choose NCache, or go another route?  Any help is appreciated.
Join the community to see this answer!
Join our exclusive community to see this answer & millions of others.
Unlock 1 Answer and 7 Comments.
Join the Community
Learn from the best

Network and collaborate with thousands of CTOs, CISOs, and IT Pros rooting for you and your success.

Andrew Hancock - VMware vExpert
See if this solution works for you by signing up for a 7 day free trial.
Unlock 1 Answer and 7 Comments.
Try for 7 days

”The time we save is the biggest benefit of E-E to our team. What could take multiple guys 2 hours or more each to find is accessed in around 15 minutes on Experts Exchange.

-Mike Kapnisakis, Warner Bros