Alastair Crabtree
Alastair Crabtree
This issues was discussed a bit in #38. In summary LazyCache will support Size using the MemoryCacheEntryOptions param as you have shown, but dynamically assigning size inside the lazily evaluated...
> I have a similar requirement but around the expiration date as I wish to cache an authentication token, the token will tell me when it will expire therefore I...
Very happy if someone would like to contribute a feature like this by implementing a new cache provider. Would suggest serialising objects using something fast like the MongoDB BSON serilaiser...
This is very similar to the newer #153 (and has the same issues)
Yes these make sense to me. There is already a provider interface, might not be perfect but should allow alternative implementations with minimal changes. Agree on a non default low...
I see your point about option 2 - a cache factory allowing for multiple caches per app with different configs. However, it does add some complexity, and personally I have...
Yeah I think the line https://github.com/alastairtree/LazyCache/blob/33d055c75b455eacf62add2ca41182b541b47981/LazyCache/CachingService.cs#L184 which is currently ``` return GetOrAddAsync(key, addItemFactory, null); ``` should be ``` return cache.GetOrAddAsync(key, addItemFactory, cache.DefaultCachePolicy.BuildOptions()); ``` Could you submit a failing test like...
Thanks for the suggestion, here are some thoughts: IObjectCache - the interface from caching abstractions we depend on in v2 - offers 2 methods * Add(...) - try to add...
> I think at the very least, it should be documented in the method (XML comments). I had to find this ticket to figure out if it was going to...
I propose we rename the method to `Set(...)` and but leave `Add(..)` as `[Obsolete]` tagged extension method for backwards compatibility. This could be a breaking change for some, so will...