Table of Contents

Interface IDestinationHealthUpdater

Namespace
Yarp.ReverseProxy.Health
Assembly
Yarp.ReverseProxy.dll

Updates destinations' health states when it's requested by a health check policy while taking into account not only the new evaluated value but also the overall current cluster's health state.

public interface IDestinationHealthUpdater

Methods

SetActive(ClusterState, IEnumerable<NewActiveDestinationHealth>)

Sets the active health values on the given destinations.

void SetActive(ClusterState cluster, IEnumerable<NewActiveDestinationHealth> newHealthStates)

Parameters

cluster ClusterState

Cluster.

newHealthStates IEnumerable<NewActiveDestinationHealth>

New active health states.

SetPassive(ClusterState, DestinationState, DestinationHealth, TimeSpan)

Sets the passive health on the given destination.

void SetPassive(ClusterState cluster, DestinationState destination, DestinationHealth newHealth, TimeSpan reactivationPeriod)

Parameters

cluster ClusterState

Cluster.

destination DestinationState

Destination.

newHealth DestinationHealth

New passive health value.

reactivationPeriod TimeSpan

If newHealth is Unhealthy, this parameter specifies a reactivation period after which the destination's Passive value will be reset to Unknown. Otherwise, it's not used.