opentelemetry-go
opentelemetry-go copied to clipboard
Add debug logging to metric signal
Similar to the trace signal we need to have a way for users to debug the system. Add logging to show flow of data.
What level of detail would you suggest? The first things that come to mind are:
- Metric name
- Timestamp
- Instrumentation library
- Labels
- Exporter type
- Aggregation type
I would think that 1, 2, 3, and 4 would have us recreating the metrics in debug logs.
Instead, I would want to capture the configuration of the SDK, similar to what the Tracer does, and events related to SDK operations, like when a periodic reader fires information related to what was exported. Maybe a line when we first create an instrument.
The goal is not to capture every interaction with our library, because the instrumentor can print their own debug with more context than we would have, but to capture the internal workings that aren't exposed to the instrumentor/user.