Don't cache connection string, use connection string factory instead
vgribok opened this issue · 4 comments
vgribok commented
Current implementation of AddPostgreSql()
and PostgreSqlHealthCheck()
caches connection string for the lifetime of the running application. This goes against the dynamic nature of IConfiguration
that allows dynamic reloading and usage of configuration settings without having to restart the application.
Please follow .NET Core Framework pattern for adding SQL Server health check for an example.
vgribok commented
Here's what I mean:
a-patel commented
I have already started working on upgrading all LiteXHealthChecks to .NET Core 3.0.
I will add factory support for all packages.