Entity Framework Core Plus Query Cache - Cache Control
EF+ Cache is very flexible and lets you have full control over the cache.
You can use your own cache:
QueryCacheManager.Cache = new MemoryCache(new MemoryCacheOptions()); context.Customers.FromCache().ToList();
You can set default policy
var options = new MemoryCacheEntryOptions() { SlidingExpiration = TimeSpan.FromHours(2)}; QueryCacheManager.DefaultMemoryCacheEntryOptions = options; context.Customers.FromCache().ToList();