Skip to content
This repository has been archived by the owner on Dec 6, 2024. It is now read-only.

OTEP 0049: LabelSet specification (to match current Metrics spec) #49

Merged
merged 22 commits into from
Nov 16, 2019

Conversation

jmacd
Copy link
Contributor

@jmacd jmacd commented Sep 13, 2019

This proposal was discussed in the Sept 10, 2019 metrics call.

Copy link
Member

@songy23 songy23 left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

./text/0000-metric-label-set.md:97:310: "acceptible" is a misspelling of "acceptable"
make: *** [Makefile:16: misspell] Error 2

Please fix.

Copy link
Member

@bogdandrutu bogdandrutu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Overall looks like this proposal removes the Handle and replace it with raw APIs on metrics that accepts a LabelSet. I think this is too much statsd model centric and we penalize all the new modern systems/protocols like prometheus and openmetrics.

If we move forward with what we agreed that all the operations happens on a Handle (except the batch record) then the only place where this optimization may have an effect is on the batch.

Based on my experience when we used the batch version like grpc/http the labels are not known at compilation time, so the label set must be constructed for every individual request so this optimization does not have any effect (adds more overhead most likely because I need to create an extra object LabelSet).

I am not sure that we need this for the moment.

text/0000-metric-label-set.md Outdated Show resolved Hide resolved
@tedsuo tedsuo added this to the Alpha v0.2 milestone Oct 8, 2019
text/0049-metric-label-set.md Outdated Show resolved Hide resolved
text/0049-metric-label-set.md Outdated Show resolved Hide resolved
text/0049-metric-label-set.md Outdated Show resolved Hide resolved
text/0049-metric-label-set.md Outdated Show resolved Hide resolved
text/0049-metric-label-set.md Outdated Show resolved Hide resolved
Copy link
Member

@iredelmeier iredelmeier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM overall.

I think it's worth making it very, very clear what is expected to live in the API and what will need to be re-implemeneted by each SDK.

text/0049-metric-label-set.md Outdated Show resolved Hide resolved
Co-Authored-By: Isobel Redelmeier <[email protected]>
Copy link
Member

@bogdandrutu bogdandrutu left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LG overall, some comments left

text/0049-metric-label-set.md Show resolved Hide resolved
In languages where overloading is a standard convenience, the metrics API may elect to offer alternate forms that elide the call to `Meter.Labels()`, for example:

```
instrument.GetHandle(meter, { Key: Value, ... })
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think this needs to be updated because instrument is now generated by the meter so no need to pass that.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Fixed.

text/0049-metric-label-set.md Show resolved Hide resolved
@bogdandrutu
Copy link
Member

One comment:
What is the behavior if a LabelSet is created by one Meter instance and the instrument was created by other Meter? This is in case of a named meter/tracer.

@jmacd
Copy link
Contributor Author

jmacd commented Nov 13, 2019

Your last question about named meters kind of made my head explode. I wish we had a standard term for the thing which is shared by all named meters, is that "provider", is that "engine", is that "SDK"? I would state that labels are usable by any meter from the same provider.

I'm adding this text

### Interaction with "Named" Meters

LabelSet values may be used with any named Meter originating from the
same Meter provider.  That is, LabelSets acquired through a named
Meter may be used by any Meter from the same Meter provider.

@bogdandrutu
Copy link
Member

This PR was opened for a long time and it has 3 official approver LGTM + few others coming from people interested in metrics. Entering God mode and merge this.

@bogdandrutu bogdandrutu merged commit 7660052 into open-telemetry:master Nov 16, 2019
@jmacd jmacd deleted the jmacd/metricslabels2 branch May 6, 2020 18:48
carlosalberto pushed a commit to carlosalberto/oteps that referenced this pull request Oct 23, 2024
…en-telemetry#49)

* Draft LabelSet spec

* Typos

* Add notes on performance expectations

* Typo

* Updates to use Monotonic/NonMonotonic, and NonNegtive/Signed

* Revert

* PR number 49

* Major revision to match the already-merged specification on LabelSet

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Accept suggested phrasing

* Revert mod changes eh?

* Update text/0049-metric-label-set.md

Co-Authored-By: Tyler Yahn <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: Isobel Redelmeier <[email protected]>

* Remove explicit meter argument where not necessary
carlosalberto pushed a commit to carlosalberto/oteps that referenced this pull request Oct 23, 2024
…en-telemetry#49)

* Draft LabelSet spec

* Typos

* Add notes on performance expectations

* Typo

* Updates to use Monotonic/NonMonotonic, and NonNegtive/Signed

* Revert

* PR number 49

* Major revision to match the already-merged specification on LabelSet

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Accept suggested phrasing

* Revert mod changes eh?

* Update text/0049-metric-label-set.md

Co-Authored-By: Tyler Yahn <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: Isobel Redelmeier <[email protected]>

* Remove explicit meter argument where not necessary
carlosalberto pushed a commit to carlosalberto/oteps that referenced this pull request Oct 30, 2024
…en-telemetry#49)

* Draft LabelSet spec

* Typos

* Add notes on performance expectations

* Typo

* Updates to use Monotonic/NonMonotonic, and NonNegtive/Signed

* Revert

* PR number 49

* Major revision to match the already-merged specification on LabelSet

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Accept suggested phrasing

* Revert mod changes eh?

* Update text/0049-metric-label-set.md

Co-Authored-By: Tyler Yahn <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: Isobel Redelmeier <[email protected]>

* Remove explicit meter argument where not necessary
carlosalberto pushed a commit to open-telemetry/opentelemetry-specification that referenced this pull request Nov 8, 2024
…en-telemetry/oteps#49)

* Draft LabelSet spec

* Typos

* Add notes on performance expectations

* Typo

* Updates to use Monotonic/NonMonotonic, and NonNegtive/Signed

* Revert

* PR number 49

* Major revision to match the already-merged specification on LabelSet

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: dyladan <[email protected]>

* Accept suggested phrasing

* Revert mod changes eh?

* Update text/0049-metric-label-set.md

Co-Authored-By: Tyler Yahn <[email protected]>

* Update text/0049-metric-label-set.md

Co-Authored-By: Isobel Redelmeier <[email protected]>

* Remove explicit meter argument where not necessary
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

10 participants