microsoft / FeatureManagement-Dotnet

Microsoft.FeatureManagement provides standardized APIs for enabling feature flags within applications. Utilize this library to secure a consistent experience when developing applications that use patterns such as beta access, rollout, dark deployments, and more.
MIT License
1.02k stars 111 forks source link

Consider using `TimeProvider` using Microsoft.Bcl.TimeProvider nuget package #451

Closed JakeYallop closed 4 days ago

JakeYallop commented 3 months ago

There is a comment in ISystemClock here: https://github.com/microsoft/FeatureManagement-Dotnet/blob/31b0efcd8c51d355c1a45a6ca98b483fd71f3f74/src/Microsoft.FeatureManagement/FeatureFilters/ISystemClock.cs#L9-L18

However this is not correct. The runtime provides a down-level package https://www.nuget.org/packages/Microsoft.Bcl.TimeProvider/ that allows TimeProvider to be used code using older versions of the runtime, or code that needs to support .NET standard.

zhiyuanliang-ms commented 3 months ago

@JakeYallop Thank you very much for paying attention to the latest changes in our repo.

This was a oversight. I didn't know there is Microsoft.Bcl.TimeProvider.

I have sent out a PR to update it. #452

zhiyuanliang-ms commented 3 months ago

The PR #452 will reference a new package. We plan to adopt this change with the next major version bump because introducing a new package might lead to potential breaking changes.