oh, I forgot: what about Output caching middleware in ASP.NET Core, is that also utilized?
Can you provide us with any specific details about what is cached? It seems like many entities are cached, right? Is there a list or high level list? Any documentation we can refer to?
Also, what about Output caching middleware in ASP.NET Core, is that also utilized?
copy that, thanks ismcagdas! 🤝
You can totally delete Redis cache but in that case, you will face problems. Each instance will have different values.
Sure, I could see that hence the underlying question, can we disable caching? Can we configure ASP.NET Zero to not cache anything? Seems like the answer is no.
Isn't the following how we configure the cache? If we set it to 0 ticks, won't every request to the cache be a miss effectively disabling the cache? What would be the negative side effects of that? Obviously potentially performance but would the application still work properly? Maybe slower, but properly?
public class OurApplicationModule : AbpModule
{
public override void PreInitialize()
{
...
Configuration.Caching.ConfigureAll(options =>
{
options.DefaultSlidingExpireTime = new TimeSpan(0);
});
}
}
reference: cache configuration
So, when you use Redis, basically, you are not using cache and it acts like as if you set cache lifetime to 0mins.
Sorry, I'm not understanding that. Redis is used for caching by definition in this application. 🤔
Redis cache basically acts as a database
Thanks (I get that)
Have you tried it?
No
what about my original question?
From reading the documentation I'm not seeing an option to disable it. Is that true? What about a workaround like setting it to 0mins?
I'm inferring from your response, the answer is "no, no way to disable it", is that correct? Any workarounds?
Thanks!
We want to deploy our application in a distributed fashion but don't want to enable distributed caching.
From reading the documentation I'm not seeing an option to disable it. Is that true? What about a workaround like setting it to 0mins?
ASP.NET Core provides different kind of caching features. In-memory cache stores your objects in the memory of the local server and is only available to the application that stored the object. Non-sticky sessions in a clustered environment should use the distributed caching except some specific scenarios (for example, you can cache a local CSS file into memory. It is read-only data and it is the same in all application instances. You can cache it in memory for performance reasons without any problem).
FIX:
in angular/src/assets/abp-web-resources/abp.js
abp.multiTenancy.tenantIdCookieName = 'Abp-TenantId';
in aspnet-core/src/Blah.Core/AccountCoreModule.cs
Configuration.MultiTenancy.TenantIdResolveKey = "Abp-TenantId";
Hello - we're having the same problem, what was the fix? thanks!