Closed johncrim closed 3 months ago
Thanks for the feedback! We are routing this to the appropriate team for follow-up. cc @cijothomas @rajkumar-rangaraj @reyang @TimothyMothra @vishweshbankwar.
@johncrim Appreciate you taking the time to open issues and offer feedback. If you'd like to set up a regular sync, shoot me an email at OTel@microsoft.com. Since OTel is evolving pretty quickly, we could try to iterate faster based on your feedback. I'll be OOF for a week in early July but will respond ASAP.
Thanks @mattmccleary - will do. I have a few other items of feedback, would be happy to discuss.
Library name and version
Azure.Monitor.OpenTelemetry.Exporter
Describe the bug
I am in the midst of switching from App Insights Classic to the OpenTelemetry exporter, and I found that the Logger exporter omits the
CategoryName
field when sending data to the App Insights endpoint.The OpenTelemetry model has LogRecord.CategoryName, and the Application Insights classic API faithfully uses the
ILogger.Name
in thecustomDimensions/CategoryName
field.Note that the
CategoryName
field is not listed on this page: https://opentelemetry.io/docs/specs/otel/logs/data-model/#log-and-event-record-definition but it IS included in other .NET docs on the opentelemetry site.This is a pretty severe oversight - I would say the green checkbox here isn't quite true! :)
Expected behavior
When using the OpenTelemetry exporter, calls to
ILogger<T>
pass all the same fields to the App Insightstraces
table as are passed using App Insights classic.Actual behavior
The
CategoryName
field is omitted from App Insights by the exporter. I've stepped through the code and verified that it's missing fromLogsHelper.OtelToAzureMonitorLogs()
.Reproduction Steps
Run the OpenTelemetry Exporter demo with an App Insights Connection string, and comment out everything except the Logger part, eg:
then run it, and note the output excludes
CategoryName
:Environment