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

Method WatchKey

kv/client.go:121–121  ·  view source on GitHub ↗

WatchKey calls f whenever the value stored under key changes.

(ctx context.Context, key string, f func(interface{}) bool)

Source from the content-addressed store, hash-verified

119
120 // WatchKey calls f whenever the value stored under key changes.
121 WatchKey(ctx context.Context, key string, f func(interface{}) bool)
122
123 // WatchPrefix calls f whenever any value stored under prefix changes. Key deletions are not notified.
124 WatchPrefix(ctx context.Context, prefix string, f func(string, interface{}) bool)

Callers 13

loopMethod · 0.65
loopMethod · 0.65
WatchKeyMethod · 0.65
WatchKeyMethod · 0.65
WatchKeyMethod · 0.65
WatchKeyMethod · 0.65
TestWatchKeyFunction · 0.65
observeValueForSomeTimeFunction · 0.65
watchBeaconsMethod · 0.65

Calls

no outgoing calls

Tested by 5

TestWatchKeyFunction · 0.52
observeValueForSomeTimeFunction · 0.52