Add HybridCache public API by mgravell · Pull Request #55084 · dotnet/aspnetcore (original) (raw)
This is the final proposed API for HybridCache (#54647) as discussed #54647
The implementation is a placeholder (that just invokes the backend service every time, i.e. no cache), and exists purely to test (via the tests project) that:
- the primary service configuration API can be used through code
- the configuration options are compatible with
ConfigurationBinder
- the primary
GetOrCreateAsync
APIs can be used through code (in particular with implicit generic typing) - it all works on .NET Framework in addition to .NET "current"
- the serializer API can at least be implemented and configured successfully (not actually used anywhere)
The code incorporates the changes and feedback from #54647
The bits that we anticipate pushing to runtime are in a sub-folder, but are in their intended namespaces.