opentelemetry-go icon indicating copy to clipboard operation
opentelemetry-go copied to clipboard

Add debug logging to metric signal

Open MrAlias opened this issue 2 years ago • 2 comments
trafficstars

Similar to the trace signal we need to have a way for users to debug the system. Add logging to show flow of data.

MrAlias avatar Feb 13 '23 17:02 MrAlias

What level of detail would you suggest? The first things that come to mind are:

  1. Metric name
  2. Timestamp
  3. Instrumentation library
  4. Labels
  5. Exporter type
  6. Aggregation type

oldclesleycode avatar Feb 15 '23 13:02 oldclesleycode

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.

MadVikingGod avatar Feb 24 '23 14:02 MadVikingGod