Class AbstractSettingsCheck
Provides a base class for health checks of configuration values.
Namespace: Umbraco.Cms.Core.HealthChecks.Checks
Assembly: Umbraco.Core.dll
Syntax
public abstract class AbstractSettingsCheck : HealthCheck, IDiscoverable
Constructors
View SourceAbstractSettingsCheck(ILocalizedTextService)
Initializes a new instance of the AbstractSettingsCheck class.
Declaration
protected AbstractSettingsCheck(ILocalizedTextService textService)
Parameters
Type | Name | Description |
---|---|---|
ILocalizedTextService | textService |
Properties
View SourceCheckErrorMessage
Gets the message for when the check has failed.
Declaration
public virtual string CheckErrorMessage { get; }
Property Value
Type | Description |
---|---|
System.String |
CheckSuccessMessage
Gets the message for when the check has succeeded.
Declaration
public virtual string CheckSuccessMessage { get; }
Property Value
Type | Description |
---|---|
System.String |
CurrentValue
Gets the current value of the config setting
Declaration
public abstract string CurrentValue { get; }
Property Value
Type | Description |
---|---|
System.String |
ItemPath
Gets key within the JSON to check, in the colon-delimited format https://docs.microsoft.com/en-us/aspnet/core/fundamentals/configuration/?view=aspnetcore-3.1
Declaration
public abstract string ItemPath { get; }
Property Value
Type | Description |
---|---|
System.String |
LocalizedTextService
Gets the localized text service.
Declaration
protected ILocalizedTextService LocalizedTextService { get; }
Property Value
Type | Description |
---|---|
ILocalizedTextService |
ReadMoreLink
Gets a link to an external resource with more information.
Declaration
public abstract string ReadMoreLink { get; }
Property Value
Type | Description |
---|---|
System.String |
ValueComparisonType
Gets the comparison type for checking the value.
Declaration
public abstract ValueComparisonType ValueComparisonType { get; }
Property Value
Type | Description |
---|---|
ValueComparisonType |
Values
Gets the values to compare against.
Declaration
public abstract IEnumerable<AcceptableConfiguration> Values { get; }
Property Value
Type | Description |
---|---|
IEnumerable<AcceptableConfiguration> |
Methods
View SourceExecuteAction(HealthCheckAction)
Executes the action and returns it's status
Declaration
public override HealthCheckStatus ExecuteAction(HealthCheckAction action)
Parameters
Type | Name | Description |
---|---|---|
HealthCheckAction | action |
Returns
Type | Description |
---|---|
HealthCheckStatus |
GetStatus()
Get the status for this health check
Declaration
public override Task<IEnumerable<HealthCheckStatus>> GetStatus()
Returns
Type | Description |
---|---|
Task<IEnumerable<HealthCheckStatus>> |
Remarks
If there are possible actions to take to rectify this check, this method must be overridden by a sub class in order to explicitly provide those actions.