-
Notifications
You must be signed in to change notification settings - Fork 55
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
Spring 6 labels not translated correctly in SpanTranslator #228
Comments
Thanks for raising the issue. Since |
I opened #229 for this. |
@rafal-dudek with the fix now merged, would you be able to try out snapshots before we cut a release? |
@shakuzen Method and Status work correctly with the snapshot: |
@rafal-dudek thanks for testing and letting us know. I'll work on a release tomorrow then. |
2.2.6 is released now with this fix. |
Describe the Bug
Since Spring 6 (Spring Boot 3), it is using micrometer-observation and own classes for Observation (Tracing).
In those versions the names of tags are changed.
E.g. There are labels "method" and "status":
https://github.com/spring-projects/spring-framework/blob/main/spring-web/src/main/java/org/springframework/http/server/observation/ServerHttpObservationDocumentation.java#L61-L77
In Spring 5 with Sleuth/OpenTracing there were "http.method" and "http.status_code" labels:
https://github.com/opentracing/opentracing-java/blob/master/opentracing-api/src/main/java/io/opentracing/tag/Tags.java#L56-L61
Zipkin-gcp provides SpanTranslator to translate those names to GCP Tracing convention:
https://github.com/openzipkin/zipkin-gcp/blob/master/translation-stackdriver/src/main/java/zipkin2/translation/stackdriver/SpanTranslator.java#L27-L36
Unfortunately, it works correctly only with Spring 5 (Spring Boot 2.X) and does not translate new labels.
The result is that after updating to Spring 6 the status code and method are treated as custom labels and are not assigned to special fields "Status" and "Method" e.g. their values are no longer visible in the summary table.
Expected Behaviour
SpanTranslator should translate new labels names from Spring 6.
The text was updated successfully, but these errors were encountered: