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

[8.x] [APM][Otel] Fix an error with mobile services coming from synthtrace (#196313) #196357

Merged
merged 1 commit into from
Oct 15, 2024

Conversation

kibanamachine
Copy link
Contributor

Backport

This will backport the following commits from main to 8.x:

Questions ?

Please refer to the Backport tool documentation

…lastic#196313)

Closes elastic#196161
## Summary

This PR fixes an issue with the mobile data using synthtrace. After some
investigation I saw that the the `httpSpan` was creating the spans with
`transaction.type` set which resulted in `processor.event` being set to
`transaction` instead of `span` - then with [the new required
transaction
fields](https://github.com/elastic/kibana/blob/adb558a86bafbe3567915c3fae252ff414147930/x-pack/plugins/observability_solution/apm/server/routes/traces/get_trace_items.ts#L277)
in get_trace_docs for transactions ([checking based on the
processor.event](https://github.com/elastic/kibana/blob/adb558a86bafbe3567915c3fae252ff414147930/x-pack/plugins/observability_solution/apm/server/routes/traces/get_trace_items.ts#L352))
we were throwing an error because the transaction fields were not
defined (which is expected because it's a span and not a transaction)

## Testing

Generate mobile data using:
`node scripts/synthtrace mobile.ts --clean`

Open all the mobile traces (ios/Android) - there should not be an error

(cherry picked from commit c218e7c)
@kibanamachine kibanamachine enabled auto-merge (squash) October 15, 2024 16:00
@botelastic botelastic bot added ci:project-deploy-observability Create an Observability project Team:obs-ux-infra_services Observability Infrastructure & Services User Experience Team labels Oct 15, 2024
@elasticmachine
Copy link
Contributor

Pinging @elastic/obs-ux-infra_services-team (Team:obs-ux-infra_services)

@kibanamachine kibanamachine merged commit e07f0d9 into elastic:8.x Oct 15, 2024
27 of 28 checks passed
@elasticmachine
Copy link
Contributor

💚 Build Succeeded

Metrics [docs]

✅ unchanged

cc @jennypavlova

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
backport ci:project-deploy-observability Create an Observability project Team:obs-ux-infra_services Observability Infrastructure & Services User Experience Team
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants