Exporting Span throws class cast exception when artemis queue messages are consumed #12216
Unanswered
Raushan-Sapiens
asked this question in
Q&A
Replies: 1 comment 9 replies
-
Can you reproduce this at will? I'd firstly try with the latest version of the agent and see if it changes anything. If the problem persists and you can reproduce this then I'd attach debugger and set exception breakpoint for |
Beta Was this translation helpful? Give feedback.
9 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
We are using java agent 1.30.0 for service which consumes queue message and have other APIs and exports span to collector. Instrumentations for APIs works well and spans are exported well to the collector.
But when queue messages are consumed, spans are failed to export. I see below error in logs
[otel.javaagent 2024-09-11 06:51:31:602 +0000] [BatchSpanProcessor_WorkerThread-1] WARN io.opentelemetry.sdk.trace.export.BatchSpanProcessor - Exporter threw an Exception
java.lang.ClassCastException: class java.lang.Double cannot be cast to class java.lang.Long (java.lang.Double and java.lang.Long are in module java.base of loader 'bootstrap')
at io.opentelemetry.exporter.internal.otlp.KeyValueMarshaler$ArrayValueMarshaler.createInt64(KeyValueMarshaler.java:223)
at io.opentelemetry.exporter.internal.otlp.KeyValueMarshaler.create(KeyValueMarshaler.java:84)
at io.opentelemetry.exporter.internal.otlp.KeyValueMarshaler.access$000(KeyValueMarshaler.java:30)
at io.opentelemetry.exporter.internal.otlp.KeyValueMarshaler$1.accept(KeyValueMarshaler.java:48)
at io.opentelemetry.exporter.internal.otlp.KeyValueMarshaler$1.accept(KeyValueMarshaler.java:43)
at java.base/java.util.HashMap.forEach(HashMap.java:1421)
at io.opentelemetry.sdk.internal.AttributesMap.forEach(AttributesMap.java:88)
at io.opentelemetry.exporter.internal.otlp.KeyValueMarshaler.createRepeated(KeyValueMarshaler.java:42)
at io.opentelemetry.exporter.internal.otlp.traces.SpanMarshaler.create(SpanMarshaler.java:44)
at io.opentelemetry.exporter.internal.marshal.MarshalerUtil.groupByResourceAndScope(MarshalerUtil.java:67)
at io.opentelemetry.exporter.internal.otlp.traces.ResourceSpansMarshaler.groupByResourceAndScope(ResourceSpansMarshaler.java:96)
at io.opentelemetry.exporter.internal.otlp.traces.ResourceSpansMarshaler.create(ResourceSpansMarshaler.java:37)
at io.opentelemetry.exporter.internal.otlp.traces.TraceRequestMarshaler.create(TraceRequestMarshaler.java:32)
at io.opentelemetry.exporter.otlp.trace.OtlpGrpcSpanExporter.export(OtlpGrpcSpanExporter.java:71)
at io.opentelemetry.sdk.trace.export.BatchSpanProcessor$Worker.exportCurrentBatch(BatchSpanProcessor.java:327)
at io.opentelemetry.sdk.trace.export.BatchSpanProcessor$Worker.run(BatchSpanProcessor.java:245)
at java.base/java.lang.Thread.run(Thread.java:833)
How can we fix/debug this? Any suggestions please
Beta Was this translation helpful? Give feedback.
All reactions