I am having a .net core 2.1 Background service application which is subscribed to a queue in Microsoft Azure Service bus. It has some logic and it calls to an api over http. I would like to create a health check for this service. Could anyone please help me out?
Asked
Active
Viewed 3,598 times
2 Answers
0
Official HealthCheck premiere was in 2.2:
https://devblogs.microsoft.com/aspnet/asp-net-core-2-2-0-preview1-healthcheck/
Health checks in ASP.NET Core 2.2:
https://learn.microsoft.com/en-us/aspnet/core/host-and-deploy/health-checks?view=aspnetcore-2.2
For 5.0:
https://learn.microsoft.com/en-us/aspnet/core/host-and-deploy/health-checks?view=aspnetcore-5.0
If you have to stay on 2.1 than I suggest to create a special endpoint for it.

velsorange
- 106
- 1
- 6
0
This worked for me https://dzone.com/articles/monitoring-health-of-aspnet-core-background-servic
It refers to use TCP probes

Daniel José Martínez Parra
- 103
- 1
- 6