Skip to content
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

[BUG] CosmosDb spans are INTERNAL and not parents of underlying HTTP spans #23032

Closed
3 tasks done
lmolkova opened this issue Jul 16, 2021 · 1 comment · Fixed by #25571
Closed
3 tasks done

[BUG] CosmosDb spans are INTERNAL and not parents of underlying HTTP spans #23032

lmolkova opened this issue Jul 16, 2021 · 1 comment · Fixed by #25571
Assignees
Labels
Azure.Core azure-core Client This issue points to a problem in the data-plane of the library.

Comments

@lmolkova
Copy link
Member

lmolkova commented Jul 16, 2021

Describe the bug

  1. CosmosDB creates public API spans, auto-instrumentation (with otel agent or app insights agent) tracks underlying HTTP calls.
    Underlying HTTP calls (there is no way to suppress them currently) are siblings (not children) of Cosmos spans and are confusing and misleading. It's also not clear if they are coming from CosmosDb or user app. To, at least, reduce the confusion, we'd like to make them children of Cosmos calls.

  2. Spans are INTERNAL, which breaks OTel expectations and means Azure Monitor can't show cosmos on the application map

To Reproduce

  1. use cosmosdb sample app
  2. add and configure appinsights agent

Code Snippet
Add the code snippet that causes the issue.

Expected behavior
http spans are children of cosmos spans (in future, we may want them to be suppressed, but OpenTelemtry does not support it at the moment).

Spans are CLIENT.

Screenshots
image

transaction link

Setup (please complete the following information):

  • OS: windows
  • IDE: IntelliJ
  • Library/Libraries: com.azure:azure-core:1.17.0, com.azure:azure-cosmos:4.17.0

Additional context
CosmosDB can't fix it without support in azure-core to create spans and make them current, and allow to specify CLIENT kind. So this needs to be addressed first.

Information Checklist
Kindly make sure that you have added all the following information above and checkoff the required fields otherwise we will treat the issuer as an incomplete report

  • Bug Description Added
  • Repro Steps Added
  • Setup information Added
@ghost ghost added the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Jul 16, 2021
@lmolkova lmolkova changed the title [BUG] CosmosDb spans are not shown as parents of underlying HTTP spans [BUG] CosmosDb spans are not parents of underlying HTTP spans Jul 16, 2021
@lmolkova lmolkova changed the title [BUG] CosmosDb spans are not parents of underlying HTTP spans [BUG] CosmosDb spans are INTERNAL and not parents of underlying HTTP spans Jul 16, 2021
@lmolkova lmolkova self-assigned this Jul 16, 2021
@lmolkova lmolkova added Client This issue points to a problem in the data-plane of the library. Monitor - ApplicationInsights Monitor - Exporter labels Jul 16, 2021
@ghost ghost removed the needs-triage Workflow: This is a new issue that needs to be triaged to the appropriate team. label Jul 16, 2021
@samvaity
Copy link
Member

Underlying HTTP calls (there is no way to suppress them currently) are siblings (not children) of Cosmos spans and are confusing and misleading.

Agreed, they should have a parent-child relation. But is this behavior true for other exporters also, apart from App Insights?

azure-sdk pushed a commit to azure-sdk/azure-sdk-for-java that referenced this issue Mar 13, 2023
@github-actions github-actions bot locked and limited conversation to collaborators Apr 11, 2023
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Azure.Core azure-core Client This issue points to a problem in the data-plane of the library.
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants