Closed azharmahmood closed 6 years ago
You would need to create your own instance of the overridden MemoryCache with the shortened expiry timer and then pass that into the constructor of the CachingService
ObjectCache innerCache = new HackedUpMemoryCacheWithShortTimer();
IAppCache cache = new CachingService(innerCache);
No reply for a while, closing.
Hello, I need absolute expiration of 7 seconds or less, but it does not expire below 15 seconds for me. Looks like there is a bug in MemoryCache, I think the same bug is causing this.
For MemoryCache folks are using a solution to override that property through reflection (please see this thread https://stackoverflow.com/questions/12630168/memorycache-absoluteexpiration-acting-strange)
What would be the best way to incorporate that in your solution, please advise?