Documentation
¶
Index ¶
- Constants
- func NewCheck() checks.Check
- type Config
- type Health
- func (h *Health) GetConfig() checks.Runtime
- func (h *Health) GetMetricCollectors() []prometheus.Collector
- func (h *Health) Name() string
- func (h *Health) RemoveLabelledMetrics(target string) error
- func (h *Health) Run(ctx context.Context, cResult chan checks.ResultDTO) error
- func (h *Health) Schema() (*openapi3.SchemaRef, error)
- func (h *Health) Shutdown()
- func (h *Health) UpdateConfig(cfg checks.Runtime) error
Constants ¶
View Source
const CheckName = "health"
Variables ¶
This section is empty.
Functions ¶
Types ¶
type Config ¶ added in v0.3.1
type Config struct { Targets []string `json:"targets,omitempty" yaml:"targets,omitempty"` Interval time.Duration `json:"interval" yaml:"interval"` Timeout time.Duration `json:"timeout" yaml:"timeout"` Retry helper.RetryConfig `json:"retry" yaml:"retry"` }
Config defines the configuration parameters for a health check
type Health ¶
Health is a check that measures the availability of an endpoint
func (*Health) GetMetricCollectors ¶
func (h *Health) GetMetricCollectors() []prometheus.Collector
GetMetricCollectors returns all metric collectors of check
func (*Health) RemoveLabelledMetrics ¶ added in v0.5.0
RemoveLabelledMetrics removes the metrics which have the passed target as a label
func (*Health) Schema ¶
Schema provides the schema of the data that will be provided by the health check
Click to show internal directories.
Click to hide internal directories.