Skip to main content

AdapterHubReadinessHealthCheck

Namespace: Meshmakers.Octo.Sdk.Common.Adapters

Readiness check: an adapter the communication controller cannot reach is not ready.

public sealed class AdapterHubReadinessHealthCheck : HubRegistrationReadinessHealthCheck, IHealthCheck

Inheritance Object → HubRegistrationReadinessHealthCheck → AdapterHubReadinessHealthCheck
Implements IHealthCheck

Remarks:

Registered with the ready tag, so it governs /healthz/ready. Before AB#5409 /healthz/ready only reported the generic 15-second startup task, so a deaf adapter answered 200 forever: five prod-1 adapters lost their hub registration during a node outage and nothing — not the probe, not the adapter entity, not the pod status — said so.

Readiness, not liveness: liveness must stay about the process (see /healthz/live, which deliberately evaluates no check at all). Note that a failing readiness probe does not restart a pod — it only takes it out of the Service endpoints and shows it as 0/1. The automatic recovery is AdapterHubRecoveryService.

The decision and its two softeners are shared with the pool member's counterpart, AdapterPoolHubReadinessHealthCheck; see HubRegistrationReadinessHealthCheck.

Constructors​

AdapterHubReadinessHealthCheck(IAdapterHubClient, IAdapterHubRegistrationState, IOptions<AdapterOptions>)​

Readiness check: an adapter the communication controller cannot reach is not ready.

public AdapterHubReadinessHealthCheck(IAdapterHubClient adapterHubClient, IAdapterHubRegistrationState registrationState, IOptions<AdapterOptions> adapterOptions)

Parameters​

adapterHubClient IAdapterHubClient

registrationState IAdapterHubRegistrationState

adapterOptions IOptions<AdapterOptions>

Remarks:

Registered with the ready tag, so it governs /healthz/ready. Before AB#5409 /healthz/ready only reported the generic 15-second startup task, so a deaf adapter answered 200 forever: five prod-1 adapters lost their hub registration during a node outage and nothing — not the probe, not the adapter entity, not the pod status — said so.

Readiness, not liveness: liveness must stay about the process (see /healthz/live, which deliberately evaluates no check at all). Note that a failing readiness probe does not restart a pod — it only takes it out of the Service endpoints and shows it as 0/1. The automatic recovery is AdapterHubRecoveryService.

The decision and its two softeners are shared with the pool member's counterpart, AdapterPoolHubReadinessHealthCheck; see HubRegistrationReadinessHealthCheck.