-
Notifications
You must be signed in to change notification settings - Fork 2.8k
[connector/spanmetrics] Fix spanmetrics for child spans #36718
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
Conversation
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
not stale |
@shivanthzen are you able to look at the failing tests? For example:
|
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
not stale |
Apparently, for delta temporality, all the metrics collected are reset to empty state after consuming one round of data. Hence storing the lastseentimestamp within the metric doesn't work. This PR moves lastseentimestamp out of metric into a map (as it was stored previously) of
b13e4d0
to
fc56cd1
Compare
@portertech Sorry about the delay. Please take another look. |
This PR was marked stale due to lack of activity. It will be closed in 14 days. |
Closed as inactive. Feel free to reopen if this PR is still being worked on. |
@portertech please review |
Please add a changelog. |
@atoulme Done |
@portertech and @Frapschen please review. |
Co-authored-by: Murphy Chen <[email protected]>
…emetry#37196) This PR contains the following updates: | Package | Change | Age | Adoption | Passing | Confidence | |---|---|---|---|---|---| | [google.golang.org/grpc](https://redirect.github.com/grpc/grpc-go) | `v1.69.2` -> `v1.69.4` | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | [](https://docs.renovatebot.com/merge-confidence/) | --- > [!WARNING] > Some dependencies could not be looked up. Check the Dependency Dashboard for more information. --- ### Release Notes <details> <summary>grpc/grpc-go (google.golang.org/grpc)</summary> ### [`v1.69.4`](https://redirect.github.com/grpc/grpc-go/releases/tag/v1.69.4): Release 1.69.4 [Compare Source](https://redirect.github.com/grpc/grpc-go/compare/v1.69.2...v1.69.4) ### Bug Fixes - rbac: fix support for :path header matchers, which would previously never successfully match ([#&open-telemetry#8203;7965](https://redirect.github.com/grpc/grpc-go/issues/7965)). ### Documentation - examples/features/csm_observability: update example client and server to use the helloworld service instead of echo service ([#&open-telemetry#8203;7945](https://redirect.github.com/grpc/grpc-go/issues/7945)). </details> --- ### Configuration 📅 **Schedule**: Branch creation - "on tuesday" (UTC), Automerge - At any time (no schedule defined). 🚦 **Automerge**: Disabled by config. Please merge this manually once you are satisfied. ♻ **Rebasing**: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox. 🔕 **Ignore**: Close this PR and you won't be reminded about this update again. --- - [ ] <!-- rebase-check -->If you want to rebase/retry this PR, check this box --- This PR was generated by [Mend Renovate](https://mend.io/renovate/). View the [repository job log](https://developer.mend.io/github/open-telemetry/opentelemetry-collector-contrib). <!--renovate-debug:eyJjcmVhdGVkSW5WZXIiOiIzOS45Mi4wIiwidXBkYXRlZEluVmVyIjoiMzkuMTA3LjAiLCJ0YXJnZXRCcmFuY2giOiJtYWluIiwibGFiZWxzIjpbImRlcGVuZGVuY2llcyIsInJlbm92YXRlYm90Il19--> --------- Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: opentelemetrybot <[email protected]> Co-authored-by: Yang Song <[email protected]>
@atoulme Does this require further approvals? |
…ry#36718) <!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description Currently, metric start timestamps are associated with the parent span (resource level). This means that all child spans, even those that occur asynchronously or infrequently, inherit the same start timestamp. This can lead to inaccurate data. This merge request proposes moving the start timestamp (and last seen timestamp) from the parent span level to the individual child span (metric) level. This will ensure that each metric has its own accurate start and last seen timestamps, regardless of its relationship to other spans. <!-- Issue number (e.g. open-telemetry#1234) or full URL to issue, if applicable. --> #### Link to tracking issue Fixes open-telemetry#35994 <!--Describe what testing was performed and which tests were added.--> #### Testing <!--Describe the documentation added.--> #### Documentation <!--Please delete paragraphs that you did not use before submitting.--> --------- Co-authored-by: Antoine Toulme <[email protected]> Co-authored-by: Murphy Chen <[email protected]> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: opentelemetrybot <[email protected]> Co-authored-by: Yang Song <[email protected]>
…ry#36718) <!--Ex. Fixing a bug - Describe the bug and how this fixes the issue. Ex. Adding a feature - Explain what this achieves.--> #### Description Currently, metric start timestamps are associated with the parent span (resource level). This means that all child spans, even those that occur asynchronously or infrequently, inherit the same start timestamp. This can lead to inaccurate data. This merge request proposes moving the start timestamp (and last seen timestamp) from the parent span level to the individual child span (metric) level. This will ensure that each metric has its own accurate start and last seen timestamps, regardless of its relationship to other spans. <!-- Issue number (e.g. open-telemetry#1234) or full URL to issue, if applicable. --> #### Link to tracking issue Fixes open-telemetry#35994 <!--Describe what testing was performed and which tests were added.--> #### Testing <!--Describe the documentation added.--> #### Documentation <!--Please delete paragraphs that you did not use before submitting.--> --------- Co-authored-by: Antoine Toulme <[email protected]> Co-authored-by: Murphy Chen <[email protected]> Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com> Co-authored-by: opentelemetrybot <[email protected]> Co-authored-by: Yang Song <[email protected]>
Description
Currently, metric start timestamps are associated with the parent span (resource level). This means that all child spans, even those that occur asynchronously or infrequently, inherit the same start timestamp. This can lead to inaccurate data.
This merge request proposes moving the start timestamp (and last seen timestamp) from the parent span level to the individual child span (metric) level. This will ensure that each metric has its own accurate start and last seen timestamps, regardless of its relationship to other spans.
Link to tracking issue
Fixes #35994
Testing
Documentation