-
Notifications
You must be signed in to change notification settings - Fork 1.1k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Metric stdout NewExportPipeline
should use ungrouped
Batcher
#425
Comments
I suggested this to @rebeccajae as a good first issue... |
I switched the stdout exporter to use the
to
This isn't including anything from the gauge options - that is, whatever is provided in |
With the With the |
But my reading is that the values aren't unspecified? Or maybe there's a bug in the example code or my understanding. |
I feel like I got caught up on "complete information" - the |
I see. I think you're right. One nice thing about There is a spec-level discussion about this topic (open-telemetry/opentelemetry-specification#345), and it appears that we are collectively leaning toward letting the empty string and the unspecified value be treated the same. It is in that sense when I say that It's possible to handle this on a case-by-case basis in an exporter. The exporter has access to the instrument descriptor, so we need not "materialize" unspecified keys before the exporter. Let's add to this ticket that the stdout exporter should materialize these itself, by scanning through the |
So the way I see it is dependent on who/what is intended to read the output of this exporter. Currently it conforms to the Prometheus spec of using an empty string to represent null/empty values. This, however has the effect of not being able to know if the value is null or the key is unspecified. If this exporter is intended to be human-readable, then it may be worthwhile to come up with a distinct way of showing these. An idea that I had was to print them as part of the name, but without the
Alternately, this could be rendered using a separate
|
Both of these suggestions are good. I'd choose the first suggestion, using |
I second that both options sounds good and also have a preference for the first one as well. |
Sorry this turned out more complicated than a trivial true->false or import change :) as you can see, the spec and code indeed are evolving, so thank you @rebeccajae :) |
Fixed by #436, thank you for your first contribution @rebeccajae! |
The defaultkeys batcher doesn't print complete information, which seems like what the user of a stdout exporter wants. The ungrouped batcher prints complete information.
The text was updated successfully, but these errors were encountered: