Microsoft.Extensions.Diagnostics.HealthChecks
A simple implementation of which uses a provided delegate to
implement the check.
Create an instance of from the specified delegate.
A delegate which provides the code to execute when the health check is run.
Runs the health check, returning the status of the component being checked.
A context object associated with the current execution.
A that can be used to cancel the health check.
A that completes when the health check has finished, yielding the status of the component being checked.
Creates a new instance of with the provided name.
The name of the health check being executed.
Options for the default service that executes instances.
Creates a new instance of .
Gets or sets the initial delay applied after the application starts before executing
instances. The delay is applied once at startup, and does
not apply to subsequent iterations. The default value is 5 seconds.
Gets or sets the period of execution. The default value is
30 seconds.
The cannot be set to a value lower than 1 second.
Gets or sets a predicate that is used to filter the set of health checks executed.
If is null, the health check publisher service will run all
registered health checks - this is the default behavior. To run a subset of health checks,
provide a function that filters the set of checks. The predicate will be evaluated each period.
Gets or sets the timeout for executing the health checks an all
instances. Use to execute with no timeout.
The default value is 30 seconds.
A service which can be used to check the status of instances
registered in the application.
The default implementation of is registered in the dependency
injection container as a singleton service by calling
.
The returned by
provides a convenience API for registering health checks.
implementations can be registered through extension methods provided by
.
Runs all the health checks in the application and returns the aggregated status.
A which can be used to cancel the health checks.
A which will complete when all the health checks have been run,
yielding a containing the results.
Runs the provided health checks and returns the aggregated status
A predicate that can be used to include health checks based on user-defined criteria.
A which can be used to cancel the health checks.
A which will complete when all the health checks have been run,
yielding a containing the results.
Options for the default implementation of
Gets the health check registrations.
Provides basic extension methods for registering instances in an .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
An instance.
The that should be reported when the health check reports a failure. If the provided value
is null, then will be reported.
A list of tags that can be used to filter health checks.
The .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
An instance.
The that should be reported when the health check reports a failure. If the provided value
is null, then will be reported.
A list of tags that can be used to filter health checks.
An optional representing the timeout of the check.
The .
Adds a new health check with the specified name and implementation.
The health check implementation type.
The .
The name of the health check.
The that should be reported when the health check reports a failure. If the provided value
is null, then will be reported.
A list of tags that can be used to filter health checks.
The .
This method will use to create the health check
instance when needed. If a service of type is registered in the dependency injection container
with any lifetime it will be used. Otherwise an instance of type will be constructed with
access to services from the dependency injection container.
Adds a new health check with the specified name and implementation.
The health check implementation type.
The .
The name of the health check.
The that should be reported when the health check reports a failure. If the provided value
is null, then will be reported.
A list of tags that can be used to filter health checks.
An optional representing the timeout of the check.
The .
This method will use to create the health check
instance when needed. If a service of type is registered in the dependency injection container
with any lifetime it will be used. Otherwise an instance of type will be constructed with
access to services from the dependency injection container.
Adds a new type activated health check with the specified name and implementation.
The health check implementation type.
The .
The name of the health check.
Additional arguments to provide to the constructor.
The .
This method will use to create the health check
instance when needed. Additional arguments can be provided to the constructor via .
Adds a new type activated health check with the specified name and implementation.
The health check implementation type.
The .
The name of the health check.
The that should be reported when the health check reports a failure. If the provided value
is null, then will be reported.
Additional arguments to provide to the constructor.
The .
This method will use to create the health check
instance when needed. Additional arguments can be provided to the constructor via .
Adds a new type activated health check with the specified name and implementation.
The health check implementation type.
The .
The name of the health check.
The that should be reported when the health check reports a failure. If the provided value
is null, then will be reported.
A list of tags that can be used to filter health checks.
Additional arguments to provide to the constructor.
The .
This method will use to create the health check
instance when needed. Additional arguments can be provided to the constructor via .
Adds a new type activated health check with the specified name and implementation.
The health check implementation type.
The .
The name of the health check.
The that should be reported when the health check reports a failure. If the provided value
is null, then will be reported.
A list of tags that can be used to filter health checks.
Additional arguments to provide to the constructor.
A representing the timeout of the check.
The .
This method will use to create the health check
instance when needed. Additional arguments can be provided to the constructor via .
Provides extension methods for registering delegates with the .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
A list of tags that can be used to filter health checks.
A delegate that provides the health check implementation.
The .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
A list of tags that can be used to filter health checks.
A delegate that provides the health check implementation.
An optional representing the timeout of the check.
The .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
A list of tags that can be used to filter health checks.
A delegate that provides the health check implementation.
The .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
A list of tags that can be used to filter health checks.
A delegate that provides the health check implementation.
An optional representing the timeout of the check.
The .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
A list of tags that can be used to filter health checks.
A delegate that provides the health check implementation.
The .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
A list of tags that can be used to filter health checks.
A delegate that provides the health check implementation.
An optional representing the timeout of the check.
The .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
A list of tags that can be used to filter health checks.
A delegate that provides the health check implementation.
The .
Adds a new health check with the specified name and implementation.
The .
The name of the health check.
A list of tags that can be used to filter health checks.
A delegate that provides the health check implementation.
An optional representing the timeout of the check.
The .
Provides extension methods for registering in an .
Adds the to the container, using the provided delegate to register
health checks.
This operation is idempotent - multiple invocations will still only result in a single
instance in the . It can be invoked
multiple times in order to get access to the in multiple places.
The to add the to.
An instance of from which health checks can be registered.
A builder used to register health checks.
Adds a for a health check.
The .
Gets the into which instances should be registered.
Throws an if is null.
The reference type argument to validate as non-null.
The name of the parameter with which corresponds.
Throws an if is null or empty.
The argument to validate as non-null and non-empty.
The name of the parameter with which corresponds.