View Source NervesHubLink.Extensions.Health.Report behaviour (nerves_hub_link v2.6.0)

Summary

Callbacks

alarms()

@callback alarms() :: %{required(String.t()) => String.t()}

checks()

@callback checks() :: %{required(String.t()) => %{pass: boolean(), note: String.t()}}

connectivity()

@callback connectivity() :: %{
  required(NervesHubLink.Extensions.Health.DeviceStatus.interface_identifer()) =>
    %{
      type: NervesHubLink.Extensions.Health.DeviceStatus.interface_type(),
      present: boolean(),
      state: atom(),
      connection_status:
        NervesHubLink.Extensions.Health.DeviceStatus.connection_status(),
      metrics: %{required(String.t()) => number()},
      metadata: %{required(String.t()) => String.t()}
    }
}

metadata()

@callback metadata() :: %{required(String.t()) => String.t()}

metrics()

@callback metrics() :: %{required(String.t()) => number()}

timestamp()

@callback timestamp() :: DateTime.t()