Replies: 1 comment 1 reply
-
|
Server span is usually create way before request processing reaches spring mvc and the route information becomes available. Consider using |
Beta Was this translation helpful? Give feedback.
1 reply
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Currently, when implementing a SpanProcessor in the OpenTelemetry Java Agent, the http.route attribute is available in the onEnd() method but not in the onStart() method for Spring MVC instrumentation. This limitation prevents use cases that require the http.route value early in the span lifecycle, such as dynamic sampling or span filtering based on the route.
Now, the url.path can be obtained in the SpanProcessor.onStart() method, but this is not what we expected.
For example, with url.path=/a/b/id=1 and url.route=/a/b/id={id}, we expect to pass /a/b/id={id} as baggage to the downstream service. Therefore, we need to obtain url.route in the SpanProcessor.onStart() method.
Beta Was this translation helpful? Give feedback.
All reactions