-
Notifications
You must be signed in to change notification settings - Fork 86
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
Possibly incorrect impl Layer for MetricsLayer
#149
Comments
The This will not globally disable any spans or events, just set up filters for this layer. |
That is not what the docs seem to be saying:
|
related issue #111 (comment) |
Yeah, the docs are right, but the implementation here always returns true for Check the |
I see! That is...very confusing 🙂 |
Thanks for clarifying @mladedav. If the implementation always returns true for |
No, it has side effects. I don't understand 100 % of the code around per-layer-filters so I hope I don't mistify you here. But the main points should be true. What happens in the background is each per-layer filter (filters which are inside Then the This maybe explains it better than I do? Basically if we remove the two methods, the filtering will not work and we'd have to get rid of the whole Removing the whole |
Thanks again for the very thorough reply @mladedav. I'm happy for this issue to be closed unless you want to track the potential work you mentioned at the end of your reply. |
Bug Report
Description
The implementation of
MetricsLayer
seems subtly incorrect to me. I don't thinkMetricsLayer
should be implementingregister_callsite
orenabled
because these methods determine whether a span or event is globally enabled (as per the docs) — which is not the behaviour I think we want.Am I missing something here? Or should these impls be removed?
The text was updated successfully, but these errors were encountered: