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

[azuremonitorexporter] LogRecordToEnvelope does not handle exceptions #38432

Open
cloudfy opened this issue Mar 6, 2025 · 2 comments · May be fixed by #38450
Open

[azuremonitorexporter] LogRecordToEnvelope does not handle exceptions #38432

cloudfy opened this issue Mar 6, 2025 · 2 comments · May be fixed by #38450
Labels
bug Something isn't working exporter/azuremonitor needs triage New item requiring triage

Comments

@cloudfy
Copy link

cloudfy commented Mar 6, 2025

Component(s)

exporter/azuremonitor

What happened?

Description

When using azuremonitor as exporter using the Otel Contrib distribution, exceptions which are logged per symantec definition of OpenTelemetry is forward to Azure Monitor as traces, not exceptions.

Steps to Reproduce

  1. Setup otel azuremonitor contrib.
  2. Configure span to include required attributes exception.type, exception.message
  3. Await data in application insights, and verify that no exceptions has been logged, but an entry in traces exists.

Expected Result

Log records of span specified as exceptions, end in the exceptions table.

Actual Result

Log records appear in traces table.

Suggested code change:

Alter log_to_envelope.go. Change LogRecordToEnvelope(*) to use contracts.NewExceptionData() when span attributes fulfill the symantec specification of an exception.

Collector version

v.0.120.0

Environment information

Environment

OS: Ubuntu 20.04 and Windows 11.102

OpenTelemetry Collector configuration

Log output

Additional context

No response

@cloudfy cloudfy added bug Something isn't working needs triage New item requiring triage labels Mar 6, 2025
Copy link
Contributor

github-actions bot commented Mar 6, 2025

Pinging code owners:

See Adding Labels via Comments if you do not have permissions to add labels yourself.

@cloudfy cloudfy linked a pull request Mar 7, 2025 that will close this issue
@cloudfy
Copy link
Author

cloudfy commented Mar 7, 2025

Suggested solution pr PR #38450

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working exporter/azuremonitor needs triage New item requiring triage
Projects
None yet
Development

Successfully merging a pull request may close this issue.

1 participant