admin管理员组

文章数量:1122846

I'm trying to trace an application based on the actor model (independent units communicating using messaging). Each actor is modeled as a service, and I'm sending the SpanContext with each message. I'm trying to track the time it takes for a message to be delivered from the sender to the target. Messages are sent without a reply, so the sender does not wait for the message to be delivered, and the span is removed from the sender before it is received.

This is shown by the two short spans in the figure below. I would like them to last until their child is created, as I want to transform them into duration metrics using SpanMetrics. I can't manually end them (after not reporting them from the sender (forgetting the rust struct)) when they are received, as it is a separate service with its own exporter.

What is the intended way to get to such a span? It seems like people are not supposed to end a span on a separate node (cf. this post). Is there a way to create/update the span in the Collector? Is there a way to calculate a delta between the parent start and the first child start in the collector (e.g., for SpanMetrics)? I see how I could get to the results using manual stream processing, but I fail to see how one is supposed to handle this. The messaging semantics did not help me answer this.

Example where the two lower short spans should last until their children are created

A span can't be stopped on the remote node, the messaging semantic does not discuss the delivery time and I did not find any way to calculate this in the collector.

本文标签: open telemetryOpenTelemetry Span for Message Delivery Time Between two ServicesStack Overflow