c# - Using InProc and Azure AppFabric Cache together -


just bit of background first. have site hosted windows azure, multiple instances , appfabric sole caching provider.

everything going great until traffic spiked earlier morning. after instances became overloaded , stopped responding came again once new instances started.

however started getting messages appfabric saying being throttled because there many requests in given hour. fair enough, giving hell.

in order avoid these messages in future planning on implementing inproc cache short lifespan. checks inproc first, if not goes appfabric, if not goes db.

 objectcache cache = memorycache.default;   cacheitempolicy policy = new cacheitempolicy();  policy.absoluteexpiration = datetimeoffset.now.addminutes(5); 

the questions have are

  • is best way handle situation?
  • is going interfere appfabric caching?
  • any issues overlooking?

update wanted chose above method , works well. using general data storage , not session state. memorycache session state not work on azure due no server affinity (as mentioned david below).

update 16-03-2012 after realizing obvious disabled sessionstate on pages. of pages don't need , hence rapidly decreases calls cache under heavy load. disabled viewstate pages well, quicker page load time.

try this: http://msdn.microsoft.com/en-us/magazine/hh708748.aspx


Comments

Popular posts from this blog

delphi - How to convert bitmaps to video? -

jasper reports - Fixed header in Excel using JasperReports -

python - ('The SQL contains 0 parameter markers, but 50 parameters were supplied', 'HY000') or TypeError: 'tuple' object is not callable -