MCPcopy Create free account
hub / github.com/TheThingsNetwork/lorawan-stack / shouldSendTelemetry

Function shouldSendTelemetry

pkg/telemetry/exporter/cli/task.go:36–38  ·  view source on GitHub ↗
(st *store.StateData)

Source from the content-addressed store, hash-verified

34var defaultTimeout = 24 * time.Hour
35
36func shouldSendTelemetry(st *store.StateData) bool {
37 return st != nil && time.Now().After(st.LastSent.Add(defaultTimeout))
38}
39
40// Option is an option for the CLI telemetry.
41type Option interface {

Callers 1

SendDataMethod · 0.85

Calls 3

AfterMethod · 0.80
NowMethod · 0.65
AddMethod · 0.65

Tested by

no test coverage detected