-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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
[connector/spanmetrics] Incorrect starttimestamps for subspans. #35994
Comments
Reopening |
… of a metric is currently tied to the root span. When a "new" child span appears for trace (eg : unhappy path on an api call which results in a new subspan or an async process that was triggered much later), the time starttimestamp for the new metric for the new child span is that of the parent span(which can be well in the past). This MR moves the start timestamp from resource level (root span) to metric level(child span) . (Doesn't consider delta-temporality as of now). References: open-telemetry#35994 Upstream Fix: open-telemetry#36019
Currently while generating metrics out of traces, the start timestamp of a metric is currently tied to the root span. When a "new" child span appears for trace (eg : unhappy path on an api call which results in a new subspan or an async process that was triggered much later), the time starttimestamp for the new metric for the new child span is that of the parent span(which can be well in the past). This MR moves the start timestamp from resource level (root span) to metric level(child span) . (Doesn't consider delta-temporality as of now). References: open-telemetry#35994 Upstream Fix: open-telemetry#36019
Ping @Frapschen @portertech |
This issue has been inactive for 60 days. It will be closed in 60 days if there is no activity. To ping code owners by adding a component label, see Adding Labels via Comments, or if you are unsure of which component this issue relates to, please ping |
@open-telemetry/collector-contrib-triagers |
Component(s)
connector/spanmetrics
What happened?
Description
Currently while generating metrics out of traces, the start timestamp of a metric is currently tied to the root span. When a "new" subspan appears for trace (eg : unhappy path on an api call which results in a new subspan), the time starttimestamp for the new metric for the new subspan is that of the root span(which can be well in the past).
Steps to Reproduce
We store start-timestamp at resource level rawmetrics in the spanconnector. This starttimestamp is used regardless of when the "new" subspan appeared.
Expected Result
The metric generated for the new span has a timestamp of the first occurance of the "new" span.
Actual Result
The metric generated for the new span has the time stamp corresponding start of the periodic trace
Collector version
v0.112.0
Environment information
Environment
OS: (e.g., "Ubuntu 20.04")
Compiler(if manually compiled): (e.g., "go 14.2")
OpenTelemetry Collector configuration
No response
Log output
No response
Additional context
No response
The text was updated successfully, but these errors were encountered: