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
2024-07-11 12:22:29 INFO traceId=994c1bec62af95447cb7df534ec2e919, parentId=, spanId=c998018b203816e8 [or.ac.GreetingService] (executor-thread-1) Sending greeting: joe
2024-07-11 12:22:29 INFO traceId=, parentId=, spanId= [or.ac.GreetingService] (vert.x-worker-thread-21) Received greeting: joe
However, the same code without blocking=true yields:
2024-07-11 12:23:40 INFO traceId=006987827ab7a89ff4e1ae783e97c8e0, parentId=, spanId=e743768e1c4f15c1 [or.ac.GreetingService] (executor-thread-1) Sending greeting: joe
2024-07-11 12:23:40 INFO traceId=006987827ab7a89ff4e1ae783e97c8e0, parentId=bddee4bb79082172, spanId=664bb0b413ba2287 [or.ac.GreetingService] (vert.x-eventloop-thread-14) Received greeting: joe
keeping the same traceId as expected. Note that the parentId is wrong in this case as it should match the spanId of the message sender.
If @WithSpan is used then a new traceId is created:
2024-07-11 13:36:20 INFO traceId=f6ddf7dd419248b49316aeddbc8c3d0a, parentId=, spanId=55857a487db338bc [or.ac.GreetingService] (executor-thread-1) Sending greeting: joe
2024-07-11 13:36:20 INFO traceId=2e7125b64d0d09b61119e01ef03a0ba2, parentId=, spanId=7bc4db3d048d96e3 [or.ac.GreetingService] (vert.x-worker-thread-39) Received greeting: joe
I'd be nice to update the docs (here and/or here) when this is implemented. It currently says that only http requests are supported for quarkus-vertx (which correlates with what I encountered). As per your findings, it looks like it is failing only with blocking = true (same as mine).
Describe the bug
When using the Vert.x event bus with
blocking = true
in@ConsumeEvent
, the OpenTelemetry context does not get propagated. For example this code:results in:
However, the same code without
blocking=true
yields:keeping the same
traceId
as expected. Note that theparentId
is wrong in this case as it should match thespanId
of the message sender.If
@WithSpan
is used then a newtraceId
is created:See also: https://quarkusio.zulipchat.com/#narrow/stream/187030-users/topic/OpenTelemetry.20and.20event.20bus.20with.20blocking.20consumer
Expected behavior
traceId
expected at the receiving end.parentId
to match thespanId
of the sender.@WithSpan
not to create a new trace.Actual behavior
traceId
propagated for non blocking consumers butparentId
is wrong.@WithSpan
a newtraceId
is created.How to Reproduce?
opentelemetry-quickstart.zip
Steps to reproduce:
opentelemetry-quickstart
serviceOutput of
uname -a
orver
Darwin AC02FW0HAMD6Q 23.5.0 Darwin Kernel Version 23.5.0: Wed May 1 20:09:52 PDT 2024; root:xnu-10063.121.3~5/RELEASE_X86_64 x86_64
Output of
java -version
openjdk version "21" 2023-09-19 OpenJDK Runtime Environment Zulu21.28+85-CA (build 21+35) OpenJDK 64-Bit Server VM Zulu21.28+85-CA (build 21+35, mixed mode, sharing)
Quarkus version or git rev
3.12.2
Build tool (ie. output of
mvnw --version
orgradlew --version
)Apache Maven 3.8.6 (84538c9988a25aec085021c365c560670ad80f63) Maven home: /Users/.../.m2/wrapper/dists/apache-maven-3.8.6-bin/67568434/apache-maven-3.8.6 Java version: 21, vendor: Azul Systems, Inc., runtime: /Users/.../.sdkman/candidates/java/21-zulu/zulu-21.jdk/Contents/Home Default locale: en_IE, platform encoding: UTF-8 OS name: "mac os x", version: "14.5", arch: "x86_64", family: "mac"
Additional information
No response
The text was updated successfully, but these errors were encountered: