alastairtree / LazyCache

An easy to use thread safe in-memory caching service with a simple developer friendly API for c#
https://nuget.org/packages/LazyCache
MIT License
1.72k stars 159 forks source link

Implement ExpirationToken for Sliding expiration #42

Closed AsValeO closed 5 years ago

AsValeO commented 6 years ago

Please, implement a ExpirationToken for sliding expiration feature like for standard MemoryCache: https://docs.microsoft.com/en-us/aspnet/core/fundamentals/primitives/change-tokens?view=aspnetcore-2.1

alastairtree commented 5 years ago

Would the MemoryCacheEntryOptions.RegisterPostEvictionCallback(...) method that is already supported fulfill your needs (as that already allows you to get notified on cache eviction)?

alastairtree commented 5 years ago

Sorry, looks like I have not been able to help. Closing as no response, but please @ reference me and I will re-open if needs be. Thanks.

AsValeO commented 3 years ago

This helped. Thank you.