Orchard caching and multiple Azure instances

Topics: Core, Customizing Orchard, General, Troubleshooting, Writing modules
Nov 12, 2014 at 2:23 PM
Is there any basic cache mechanism in Orchard that works accross multiple Azure instances? "Works" meaning "the cache is synchronized between all instances at any point in time".

Currently we use the default cache manager (Orchard.Caching.DefaultCacheManager) and default cache holder (Orchard.Caching.DefaultCacheHolder) but when using:
var myValue = this.CacheManager.Get(
    ctx =>
        return this.GetData(key);
The results just change depending on the instance.
Nov 12, 2014 at 3:34 PM
Edited Nov 13, 2014 at 7:48 AM
OK, just read this link: http://docs.orchardproject.net/Documentation/Caching

So if I understand correctly I need to enable the Orchard.Caching module and use Orchard.Caching.Services.ICacheService instead of ICacheManager. Or should I use the Orchard.Caching.Memcached module as well? What should I configure in order to use these modules with Azure?

Well it seems like Orchard.Caching is using HttpRuntime.Cache as its internal storage provider, and as far as I can tell this is also an in-memory cache which will get us the same behavior.

Orchard.Caching.Memcached seems like a better option but the module linked in the documentation is near-empty : it's a simple wrapper around IMemcachedClientHolder and it depends on another Memcached module which I can't find (the only reference to IMemcachedClientHolder I can find in google is from the Contrib.Cache.Memcached module, used for output caching).