Press Ctrl / CMD + C to copy this to your clipboard.
This post will be reported to the moderators as potential spam to be looked at
Hi guys,
I have a following code and i can't seems to work out whats wrong and why.
private static MemoryCache _cache = new MemoryCache("CacheManager"); public static bool IsNavigationCacheEmpty() { return !_cache.Contains("ProductChannelItem"); }
And when i call IsNavigationCacheEmpty() method, it works fine if the controller is inherited from
Umbraco.Web.Mvc.RenderMvcController
but if it inherits from normal controller, it always return null
System.Web.Mvc.Controller
In Summary cache set under Umbraco Controller can't be detected by normal Controller, tho its running under the same website / application pool.
Also this only seems to happen in our Windows 2008 R2 server, works fine on Windows 8.1 dev machine
Any of you guys had this issue? or know why this could occur?
Currently web site is running under .net 4.5.1
Thank you
Shinsuke
is working on a reply...
Write your reply to:
Upload image
Image will be uploaded when post is submitted
System.Runtime.Caching,MemoeryCache Issue
Hi guys,
I have a following code and i can't seems to work out whats wrong and why.
And when i call IsNavigationCacheEmpty() method, it works fine if the controller is inherited from
but if it inherits from normal controller, it always return null
In Summary cache set under Umbraco Controller can't be detected by normal Controller, tho its running under the same website / application pool.
Also this only seems to happen in our Windows 2008 R2 server, works fine on Windows 8.1 dev machine
Any of you guys had this issue? or know why this could occur?
Currently web site is running under .net 4.5.1
Thank you
Shinsuke
is working on a reply...