You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I see issues setting MaxRdSecond to 0 or -1 has no effect
There is no such case. Why? In addition, the documentation of UseFasterKv is too few. I can only know from the preferred documentation that it is similar to the combination of UseInMemory and UseDisk. I don't know if this is the right understanding, there is so little documentation
The text was updated successfully, but these errors were encountered:
Thank you. Can UseInMemory and UseDisk be used together? Like, if the content cache does not match, it will automatically search the hard disk cache. Reassigning the cache automatically fills both caches but their lifetimes can be set separately, right?
Thank you. Can UseInMemory and UseDisk be used together? Like, if the content cache does not match, it will automatically search the hard disk cache. Reassigning the cache automatically fills both caches but their lifetimes can be set separately, right?
IServiceCollection services = new ServiceCollection();
services.AddEasyCaching(option =>
{
//use fasterkv cache
option.UseFasterKv(config =>
{
config.EnableLogging = true;
config.MaxRdSecond = -1;
}, "testcaching").WithMessagePack("testcaching");
});
IServiceProvider serviceProvider = services.BuildServiceProvider();
var factory = serviceProvider.GetService();
var caching = factory.GetCachingProvider("testcaching");
caching.TrySet("testcaching", $"testcachingmsg", TimeSpan.FromSeconds(1));
var msg = caching.Get("testcaching");
Debug.WriteLine($"caching msg->{msg}");
Thread.Sleep(3000);
var msg2 = caching.Get("testcaching", () => "12345", TimeSpan.FromSeconds(1));
Debug.WriteLine($"caching msg2->{msg2}");
print is
11:57:26:112 caching msg->testcachingmsg
11:57:29:114 caching msg2->testcachingmsg
I see issues setting MaxRdSecond to 0 or -1 has no effect
There is no such case. Why? In addition, the documentation of UseFasterKv is too few. I can only know from the preferred documentation that it is similar to the combination of UseInMemory and UseDisk. I don't know if this is the right understanding, there is so little documentation
The text was updated successfully, but these errors were encountered: