Skip to content
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

Make multi-instrument idioms for async callbacks possible #2281

Closed
wants to merge 3 commits into from

Conversation

jmacd
Copy link
Contributor

@jmacd jmacd commented Jan 20, 2022

Fixes #2280

Changes

This changes slightly the requirement for how instruments are associated with callbacks. Whereas before the spec required one instrument per callback, this would allow multiple instruments. A motivating example is given in #2280.

Related issues #2270 #2249

@jmacd jmacd added the spec:metrics Related to the specification/metrics directory label Jan 20, 2022
@jmacd jmacd requested review from a team January 20, 2022 22:59
@jack-berg
Copy link
Member

I believe we also need to loosen the requirement that APIs produce an error when multiple instruments are registered with the same name.

Does that make sense to do in this PR or in a separate one?

@jmacd
Copy link
Contributor Author

jmacd commented Jan 21, 2022

@jack-berg this PR definitely depends on #2270.

Copy link
Contributor

@jsuereth jsuereth left a comment

Choose a reason for hiding this comment

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

Thanks for tweaking this @jmacd !

@jack-berg
Copy link
Member

It seems natural that if multiple callbacks allowed, that there should be some way of unregister / cancel / stop callbacks #2232. But I think that can be solved separately.

@jmacd
Copy link
Contributor Author

jmacd commented Feb 2, 2022

Reviewers, as noted in #2226 (comment) I am closing this PR. This work will be integrated into #2270 following the discussion in #2226.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area:api Cross language API specification issue spec:metrics Related to the specification/metrics directory
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Enable multi-instrument callbacks in the metrics API
8 participants