MCPcopy
hub / github.com/grafana/tempo / sleepWithContext

Method sleepWithContext

cmd/tempo-vulture/validation.go:254–262  ·  view source on GitHub ↗
(ctx context.Context, duration time.Duration)

Source from the content-addressed store, hash-verified

252)
253
254func (vs *ValidationService) sleepWithContext(ctx context.Context, duration time.Duration) error {
255 select {
256 case <-ctx.Done():
257 return ctx.Err()
258 default:
259 vs.clock.Sleep(duration)
260 return nil
261 }
262}
263
264func (vs *ValidationService) writeValidationTrace(
265 _ context.Context,

Callers 1

RunValidationMethod · 0.95

Calls 2

DoneMethod · 0.65
SleepMethod · 0.65

Tested by

no test coverage detected