Log emits a structured log line for every metric call. Cheap and portable; production aggregators (Loki, CloudWatch, Datadog) can build counters and gauges from these directly. All lines share the [metrics] prefix so they're easy to filter. Format is key=value space-separated, which both jq and Spl
| 81 | // Format is key=value space-separated, which both jq and Splunk parse |
| 82 | // natively. |
| 83 | type Log struct { |
| 84 | // inflightPublisherLag is set by SetPublisherLag and emitted |
| 85 | // every N calls (currently 60 — once a minute at the worker's |
| 86 | // 1s poll cadence). Saves log volume. |
| 87 | calls atomic.Int64 |
| 88 | } |
| 89 | |
| 90 | func NewLog() *Log { return &Log{} } |
| 91 |
nothing calls this directly
no outgoing calls
no test coverage detected