Xabaril / AspNetCore.Diagnostics.HealthChecks

Enterprise HealthChecks for ASP.NET Core Diagnostics Package
Apache License 2.0
3.98k stars 771 forks source link

Could not load type 'SqlGuidCaster' from assembly Microsoft.Data.SqlClient #2182

Closed aj-scram closed 3 months ago

aj-scram commented 3 months ago

Recently upgrade project from .net7 to .net8 and immediately ran into this old https://github.com/dotnet/SqlClient/issues/1930

Seems that the root cause is any older version of Microsoft.Data.SqlClient (<5.2.0) than the newest release not playing well with reflection calls loading types/assemblies.

Could we get AspNetCore.HealthChecks.SqlServer to update to use the new version?

unaizorrilla commented 3 months ago

I just create a PR for this #2183, waiting for review!

unaizorrilla commented 3 months ago

A package for SqlServer with version 8.0.1 is published, the process take some time to index the package befor is listed on Nuget!