You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The names should be more generic according to the docs of OpenTelemetry (which is the successor of OpenTracing):
The span name SHOULD be the most general string that identifies a (statistically) interesting class of Spans, rather than individual Span instances while still being human-readable. That is, “get_user” is a reasonable name, while “get_user/314159”, where “314159” is a user ID, is not a good name due to its high cardinality. Generality SHOULD be prioritized over human-readability. — https://opentelemetry.io/docs/reference/specification/trace/api/#span
and:
Many REST APIs encode parameters into URI path, e.g. /api/users/123 where 123 is a user id, which creates high cardinality value space not suitable for span names. In case of HTTP servers, these endpoints are often mapped by the server frameworks to more concise HTTP routes, e.g. /api/users/{user_id}, which are recommended as the low cardinality span names. — https://opentelemetry.io/docs/reference/specification/trace/semantic_conventions/http/#name
I think using the plain URL also might put necessary stress to the Tracing systems.
As an alternative we could replace the URL we with the route name as soon as it is available in the KernelEvents::CONTROLLER event ($event->getRequest()->attributes->get('_route').
Thank you!
The text was updated successfully, but these errors were encountered:
Root span names have a high cardinality, because they use the plain request URI:
OpentracingBundle-core/EventListener/StartRootSpanSubscriber.php
Lines 61 to 64 in 2cbf03e
The names should be more generic according to the docs of OpenTelemetry (which is the successor of OpenTracing):
and:
I think using the plain URL also might put necessary stress to the Tracing systems.
As an alternative we could replace the URL we with the route name as soon as it is available in the
KernelEvents::CONTROLLER
event ($event->getRequest()->attributes->get('_route')
.Thank you!
The text was updated successfully, but these errors were encountered: