MCPcopy
hub / github.com/grafana/dskit / IsHealthy

Method IsHealthy

ring/model.go:176–180  ·  view source on GitHub ↗
(op Operation, heartbeatTimeout time.Duration, now time.Time)

Source from the content-addressed store, hash-verified

174}
175
176func (i *InstanceDesc) IsHealthy(op Operation, heartbeatTimeout time.Duration, now time.Time) bool {
177 healthy := op.IsInstanceInStateHealthy(i.State)
178
179 return healthy && i.IsHeartbeatHealthy(heartbeatTimeout, now)
180}
181
182// IsHeartbeatHealthy returns whether the heartbeat timestamp for the ingester is within the
183// specified timeout period.

Calls 2

IsHeartbeatHealthyMethod · 0.95