Reputation: 59
I've been working on getting some basic metrics setup within Azure Application Insights. In the Website and the API I am setting the application version using a TelemetryInitializer and am able to filter by this for Server Requests:
telemetry.Context.Component.Version = "1.0";
When I try to filter or group by Application Version for other types of requests (for example, Users or Exceptions), it shows up as undefined. Does anyone know how to make this kind of filtering work?
Here's what I see in the metrics explorer (ignore all of the undefined requests on the server requests, as they were from before the version was set, and some of the other APIs).
[
Upvotes: 4
Views: 3379
Reputation: 25116
telemetry.Context.Component.Version = "1.0";
should totally work, and it looks like it is for the requests.
couple things i can think of:
the exceptions are browser (javascript) exceptions, not server exceptions, so they're not getting your context.
the exceptions are occurring either
a. before you're setting the version on the context, or
b. are happening on another telemetry context, that doesn't have your version set?
Upvotes: 2