dotnetcore / EasyCaching

:boom: EasyCaching is an open source caching library that contains basic usages and some advanced usages of caching which can help us to handle caching more easier!
MIT License
1.92k stars 321 forks source link

GetAsync with DataRetriever doesn't allow to set TimeSpan.Zero to expiration #479

Open jkatsiotis opened 1 year ago

jkatsiotis commented 1 year ago

I believe expiration parameter should be a nullable TimeSpan.

How does that sound?

catcherwong commented 1 year ago

@jkatsiotis Thanks for your interest in this project.

In v1.x, the expiration was designed a not nullable parameter, all cached values should be hot cache, not cold cache.

And this feature will in v2.x. (https://github.com/dotnetcore/EasyCaching/discussions/470)