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

Metrics examplars

Open dyladan opened this issue 2 years ago • 10 comments

Spec: https://github.com/open-telemetry/opentelemetry-specification/blob/main/specification/metrics/sdk.md#exemplar

A metrics exemplar is a trace that is representative of the metrics being collected. The spec requires that exemplars be implemented in a way such that they may be disabled and that if disabled they should have no performance impact (collection should be disabled, not just export). When enabled, the exemplars will come from the currently active context.

Properties:

  • Value

  • Time

  • Attributes

  • Trace ID

  • Span ID

  • ExemplarFilter determines if a meausrement should be sampled

    • value of measurement
    • attributes of measurement
    • context of measurement
    • timestamp
  • ExemplarReservoir provides a method to offer measurements to the reservoir and to collect accumulated exemplars

    • Methods
      • offer
        • value of measurement
        • attributes of measurement
        • context of measurement
        • timestamp
      • collect
        • returns accumulated exemplars

Built-in reservoirs

  • SimpleFixedSizeExemplarReservoir
  • AlignedHistogramBucketExemplarReservoir

dyladan avatar Nov 03 '21 15:11 dyladan

Happy to take this up if no one has already started working on it

srikanthccv avatar Nov 17 '21 16:11 srikanthccv

go ahead. You may want to keep an eye on #2625 since it changes what we have quite a bit

dyladan avatar Nov 17 '21 16:11 dyladan

@lonewolf3739 a friendly question: are you planning to work on the integration of metric exemplars and the View API?

legendecas avatar Dec 29 '21 16:12 legendecas

@legendecas yes, that's why I didn't use fixes in the PR description that would close this issue. And there is also tiny env related work to do. I will work on the wiring up the stuff as well when other components are ready.

srikanthccv avatar Dec 29 '21 16:12 srikanthccv

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.

github-actions[bot] avatar Feb 28 '22 06:02 github-actions[bot]

This issue is stale because it has been open 60 days with no activity. Remove stale label or comment or this will be closed in 14 days.

github-actions[bot] avatar May 02 '22 06:05 github-actions[bot]

Hi @srikanthccv :slightly_smiling_face:

Friendly question: are you still planning to work on this? :thinking: Otherwise I'll mark this as up-for-grabs in case someone else has some cycles to work on it. :slightly_smiling_face:

pichlermarc avatar Sep 20 '22 05:09 pichlermarc

@pichlermarc I won't be able to allocate time for this - unassigning myself. Thanks.

srikanthccv avatar Sep 20 '22 05:09 srikanthccv

Hello team, any update on this? I am waiting for this feature, I am would like to setup a Nodejs application work with Exemplars, Prometheus and Tempo

vothanhbinhlt avatar Nov 24 '22 05:11 vothanhbinhlt

AFAIK no one is currently working on this. Interest in it might pick up once the specification is marked stable.

pichlermarc avatar Nov 24 '22 09:11 pichlermarc