Show the simplest way to use health check functionality using app.UseHealthChecks
.
Customize the message returned by app.UseHealthChecks
.
Start implementing IHealthCheck
to provide status information for the health check service. In this example, it will always return failure because we just throw an exception in the implementation. You will see how the health check handles an unhandled exception.
Implement a IHealthCheck
that check the status of a url. This is the first version of the check so it is primitive but it is also easier to understand. We will go to a more sophisticated multi check in the next examples.
Similar to the previous example except that now there are two checks, one fails and one successful.
Similar to the previous example except that one of the check reports "Degraded" status by using context.Registration.FailureStatus = HealthStatus.Degraded;
.
此处可能存在不合适展示的内容,页面不予展示。您可通过相关编辑功能自查并修改。
如您确认内容无涉及 不当用语 / 纯广告导流 / 暴力 / 低俗色情 / 侵权 / 盗版 / 虚假 / 无价值内容或违法国家有关法律法规的内容,可点击提交进行申诉,我们将尽快为您处理。