MCPcopy Create free account
hub / github.com/CrunchyData/postgres-operator / NewTickerImmediate

Function NewTickerImmediate

internal/controller/runtime/ticker.go:33–36  ·  view source on GitHub ↗

NewTickerImmediate returns a Source that emits e at start and every d.

(d time.Duration, e event.GenericEvent,
	h handler.EventHandler)

Source from the content-addressed store, hash-verified

31
32// NewTickerImmediate returns a Source that emits e at start and every d.
33func NewTickerImmediate(d time.Duration, e event.GenericEvent,
34 h handler.EventHandler) source.Source {
35 return &ticker{Duration: d, GenericEvent: e, Handler: h, Immediate: true}
36}
37
38func (t ticker) String() string { return "every " + t.Duration.String() }
39

Callers 1

TestTickerFunction · 0.85

Calls

no outgoing calls

Tested by 1

TestTickerFunction · 0.68