MCPcopy Index your code
hub / github.com/cortexproject/cortex / IsHealthy

Method IsHealthy

pkg/ring/model.go:137–141  ·  view source on GitHub ↗
(op Operation, heartbeatTimeout time.Duration, storageLastUpdated time.Time)

Source from the content-addressed store, hash-verified

135}
136
137func (i *InstanceDesc) IsHealthy(op Operation, heartbeatTimeout time.Duration, storageLastUpdated time.Time) bool {
138 healthy := op.IsInstanceInStateHealthy(i.State)
139
140 return healthy && i.IsHeartbeatHealthy(heartbeatTimeout, storageLastUpdated)
141}
142
143// IsHeartbeatHealthy returns whether the heartbeat timestamp for the ingester is within the
144// specified timeout period. A timeout of zero disables the timeout; the heartbeat is ignored.

Calls 2

IsHeartbeatHealthyMethod · 0.95