internal static void ClearCache() { var tenantId = CoreContext.TenantManager.GetCurrentTenant().TenantId.ToString(); var path = TenantPath.CreatePath(tenantId); foreach (var module in GetModuleList("", true)) { Cache.Publish(DataStoreCacheItem.Create(path, module), CacheNotifyAction.Remove); } }
public static void Remove(string tenantId, string module) { Cache.Remove(DataStoreCacheItem.Create(tenantId, module).MakeCacheKey()); }
public static IDataStore Get(string tenantId, string module) { return(Cache.Get <IDataStore>(DataStoreCacheItem.Create(tenantId, module).MakeCacheKey())); }
public static void Put(IDataStore store, string tenantId, string module) { Cache.Insert(DataStoreCacheItem.Create(tenantId, module).MakeCacheKey(), store, DateTime.MaxValue); }